dochelper
Class TableRecord

java.lang.Object
  extended by dochelper.TableRecord
All Implemented Interfaces:
Record

public class TableRecord
extends java.lang.Object
implements Record


Field Summary
protected  java.util.HashMap _fieldValues
          HashMap containing each field within this Record (Row) and its value.
protected  java.util.HashMap _fullFieldValues
          HashMap containing each field within this Record (Row) and its value.
protected  java.lang.String _name
          HashMap containing each field within this Record (Row) and its value.
 
Constructor Summary
TableRecord(java.util.HashMap fieldValues)
          Creates a new instance of TableRecord
TableRecord(java.util.HashMap fieldValues, java.util.HashMap fullFieldValues, java.lang.String name)
          Creates a New Instance of a Table Record, given a set of values and a Document Section
 
Method Summary
 ResultNode execute(java.util.ArrayList<DocPattern> patterns)
          Renders a record using the specified Pattern list.
 java.lang.String getValue()
          Return the string value of this record.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

_fieldValues

protected java.util.HashMap _fieldValues
HashMap containing each field within this Record (Row) and its value.


_fullFieldValues

protected java.util.HashMap _fullFieldValues
HashMap containing each field within this Record (Row) and its value.


_name

protected java.lang.String _name
HashMap containing each field within this Record (Row) and its value.

Constructor Detail

TableRecord

public TableRecord(java.util.HashMap fieldValues)
Creates a new instance of TableRecord

Parameters:
fieldValues -

TableRecord

public TableRecord(java.util.HashMap fieldValues,
                   java.util.HashMap fullFieldValues,
                   java.lang.String name)
Creates a New Instance of a Table Record, given a set of values and a Document Section

Parameters:
fieldValues - hashMap containing field names and field values for Searched Fields
fullFieldValues - HashMap containing all field names and its values
name -
Method Detail

execute

public ResultNode execute(java.util.ArrayList<DocPattern> patterns)
Renders a record using the specified Pattern list. This method will iterate through all patterns passed in if any, and execute the pattern passing the contents of the row this record represents. In this case the value of the record will not be fetched using getValue. It will be fetched directly from the fieldValues has map.

Specified by:
execute in interface Record
Parameters:
patterns - ArrayList list of pattern that should be used during the rendering process for this record.
Returns:
String containing the contents of the pattern rendering and the encapsulation.

getValue

public java.lang.String getValue()
Return the string value of this record. For table record sets this value is not used as the string to search against. Each field in a row is checked indiidually.

Specified by:
getValue in interface Record
Returns:
String value of the entire record.