public abstract class HashRecord extends java.lang.Object implements Record
| Constructor and Description |
|---|
HashRecord() |
| Modifier and Type | Method and Description |
|---|---|
java.lang.Object |
clone()
Clones the Record.
|
void |
convertFieldValuesToCorrectType()
This method uses ConversionLib.convertToFoo() and related tools to attempt to convert values
to the type specified by the field definitions for this HashRecord.
|
Naming |
convertToNaming()
Converts this HashRecord object to a more modern (and simpler) Naming
structure.
|
java.util.Iterator |
editableFields()
A list of FieldDefs describing all the editable (readable and writable)
in this Record.
|
protected abstract java.util.Map |
editableFieldsDict() |
void |
forceFieldValuesToCorrectType()
This method uses ConversionLib.forceToFoo() and related tools to attempt to forcibly convert values
to the type specified by the field definitions for this HashRecord.
|
java.util.Map |
getAllFieldValues()
Field values for all editable fields.
|
FieldDef |
getField(java.lang.String fieldName)
Returns a FieldDef for the given field.
|
java.lang.Object |
getFieldValue(java.lang.String fieldName)
Gets the value for a given field.
|
java.util.Map |
getFieldValues()
Field values for all readable fields.
|
java.util.Iterator |
readableFields()
A list of FieldDefs describing all the readable fields in this Record.
|
protected abstract java.util.Map |
readableFieldsDict() |
void |
setFieldValue(java.lang.String fieldName,
java.lang.Object value)
Sets the value for a given field.
|
void |
setFieldValues(java.util.Map newFields)
Sets field values.
|
public FieldDef getField(java.lang.String fieldName)
public java.util.Iterator readableFields()
readableFields in interface Recordpublic java.util.Iterator editableFields()
editableFields in interface Recordpublic java.lang.Object getFieldValue(java.lang.String fieldName)
throws NoSuchFieldInRecordException
getFieldValue in interface RecordNoSuchFieldInRecordExceptionpublic void setFieldValue(java.lang.String fieldName,
java.lang.Object value)
throws NoSuchFieldInRecordException,
java.lang.IllegalArgumentException
setFieldValue in interface RecordNoSuchFieldInRecordExceptionjava.lang.IllegalArgumentExceptionpublic java.util.Map getFieldValues()
getFieldValues in interface Recordpublic java.util.Map getAllFieldValues()
getAllFieldValues in interface Recordpublic void setFieldValues(java.util.Map newFields)
Invalid fields are ignored.
setFieldValues in interface RecordnewFields - A dictionary of fieldnames associated with their values.public java.lang.Object clone()
public Naming convertToNaming()
public void convertFieldValuesToCorrectType()
public void forceFieldValuesToCorrectType()
protected abstract java.util.Map readableFieldsDict()
protected abstract java.util.Map editableFieldsDict()