com.servingxml.util.record
Interface Record

All Known Implementing Classes:
AbstractRecord, ParameterBuilder, RecordBuilder, RecordImpl, ServingXmlParameters

public interface Record

A Record class represents a set of fields.


Field Summary
static Record EMPTY
           
static Record[] EMPTY_ARRAY
           
static Name EMPTY_RECORD_TYPE_NAME
           
 
Method Summary
 org.xml.sax.XMLReader createXmlReader(PrefixMap prefixMap)
          Gets an XMLReader representation of the record.
 int fieldCount()
           
 Name getFieldName(int i)
           
 java.lang.Object getObject(Name name)
          Gets the value of a field as a Java object.
 RecordType getRecordType()
           
 java.lang.String getString(Name name)
          Gets the value of a field as a string.
 java.lang.String[] getStringArray(Name name)
          Gets the value of a field as a string array.
 Value getValue(int index)
          Gets the value of a field at the specified index.
 Value getValue(Name name)
          Gets the value of a field with the specified name.
 java.lang.String toXmlString(PrefixMap prefixMap)
           
 void writeToContentHandler(PrefixMap prefixMap, org.xml.sax.ContentHandler handler)
           
 

Field Detail

EMPTY_RECORD_TYPE_NAME

static final Name EMPTY_RECORD_TYPE_NAME

EMPTY

static final Record EMPTY

EMPTY_ARRAY

static final Record[] EMPTY_ARRAY
Method Detail

getRecordType

RecordType getRecordType()

fieldCount

int fieldCount()

getFieldName

Name getFieldName(int i)

getString

java.lang.String getString(Name name)
Gets the value of a field as a string.

Parameters:
name - The field name.
Returns:
The field value as a string.

getStringArray

java.lang.String[] getStringArray(Name name)
Gets the value of a field as a string array.

Parameters:
name - The field name.
Returns:
The field value as a string array.

getValue

Value getValue(Name name)
Gets the value of a field with the specified name.

Parameters:
name - The field name.
Returns:
The field value

getValue

Value getValue(int index)
Gets the value of a field at the specified index.

Parameters:
index - the index of the field.
Returns:
The field value

createXmlReader

org.xml.sax.XMLReader createXmlReader(PrefixMap prefixMap)
Gets an XMLReader representation of the record.

Returns:
An XMLReader representation of the record.

getObject

java.lang.Object getObject(Name name)
Gets the value of a field as a Java object.

Parameters:
name - The field name.
Returns:
The field value

toXmlString

java.lang.String toXmlString(PrefixMap prefixMap)

writeToContentHandler

void writeToContentHandler(PrefixMap prefixMap,
                           org.xml.sax.ContentHandler handler)
                           throws org.xml.sax.SAXException
Throws:
org.xml.sax.SAXException