|
|||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||
java.lang.Object | +--com.ashridgetech.prevdb.client.FieldMap
A mapping from a set of a persistent fields of one Persistent class to their values,
in one Persistent object. Can be used with
the Persistent interface to get or set fields. Field values cannot be removed once set, but they
can be set more than once (although this is not recommended). The fields are stored in the order in which they
are set by calls to setFieldValue(com.ashridgetech.prevdb.client.PersistentField, java.lang.Object).
| Constructor Summary | |
FieldMap(Class persistentClass,
Object oid)
Creates a new FieldMap for a particular persistent class and oid. |
|
FieldMap(Persistent obj)
Creates a new FieldMap for a particular persistent object. |
|
| Method Summary | |
Set |
getFields()
Get the set of fields in this FieldMap, in the order in which they were set. |
Object |
getFieldValue(PersistentField field)
Get a field value that is known to be held in this FieldMap |
Object |
getOid()
Get the oid |
Class |
getPersistentClass()
Get the class to which this FieldMap belongs |
boolean |
hasFieldValue(PersistentField field)
Indicate whether this FieldMap has a value for a particular field |
boolean |
isMapFor(Persistent obj)
Show whether this FieldMap holds field values for a given Persistent object. |
void |
setFieldValue(PersistentField field,
Object value)
Set a field value in this FieldMap |
String |
toString()
|
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Constructor Detail |
public FieldMap(Class persistentClass,
Object oid)
FieldMap for a particular persistent class and oid.
persistentClass - the class of object for which this FieldMap stores fields and valuesoid - the object id of the Persistent to which the field values in this FieldMap applypublic FieldMap(Persistent obj)
FieldMap for a particular persistent object.
obj - the object for which this FieldMap stores fields and values| Method Detail |
public Class getPersistentClass()
FieldMap belongs
FieldMap belongspublic Object getOid()
Persistent to which the field values in this FieldMap applypublic boolean isMapFor(Persistent obj)
FieldMap holds field values for a given Persistent object.
obj - the persistent object to checkpublic Object getFieldValue(PersistentField field)
FieldMap
field - the field for which a value is required
hasFieldValue(com.ashridgetech.prevdb.client.PersistentField)
public void setFieldValue(PersistentField field,
Object value)
FieldMap
field - the field for which a value is to be set
getFieldValue(com.ashridgetech.prevdb.client.PersistentField)public boolean hasFieldValue(PersistentField field)
FieldMap has a value for a particular field
field - the field for which a value is required
true if this FieldMap has a value for fieldpublic Set getFields()
FieldMap, in the order in which they were set.
PersistentField objectspublic String toString()
toString in class Object
|
|||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||