|
|||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||
java.lang.Object | +--com.ashridgetech.prevdb.client.FieldChangeMap
A mapping from a set of a persistent fields of one Persistent class to their values and
their old values. Holds two FieldMaps.
| Constructor Summary | |
FieldChangeMap(Class persistentClass,
Object oid)
Creates a new FieldChangeMap for a particular persistent class and oid. |
|
FieldChangeMap(Persistent obj)
Creates a new FieldChangeMap for a particular persistent object. |
|
| Method Summary | |
Set |
getFields()
Get the set of fields in this FieldChangeMap |
FieldMap |
getNewFieldMap()
Get the FieldMap of new values. |
Object |
getNewFieldValue(PersistentField field)
Get the new value of a field that is known to be held in this FieldChangeMap |
Object |
getOid()
Get the oid |
FieldMap |
getOldFieldMap()
Get the FieldMap of old values. |
Object |
getOldFieldValue(PersistentField field)
Get the old value of a field that is known to be held in this FieldChangeMap |
Class |
getPersistentClass()
Get the class to which this FieldChangeMap belongs |
boolean |
hasFieldValue(PersistentField field)
Indicate whether this FieldChangeMap has a value for a particular field |
boolean |
isMapFor(Persistent obj)
Show whether this FieldChangeMap holds field values for a given Persistent object. |
void |
setFieldValues(PersistentField field,
Object oldValue,
Object newValue)
Set a field value in this FieldChangeMap |
String |
toString()
|
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Constructor Detail |
public FieldChangeMap(Class persistentClass,
Object oid)
FieldChangeMap for a particular persistent class and oid.
persistentClass - the class of object for which this FieldChangeMap stores fields and old and new valuesoid - the object id of the Persistent to which the field values in this FieldMap applypublic FieldChangeMap(Persistent obj)
FieldChangeMap for a particular persistent object.
obj - the object for which this FieldChangeMap stores field changes| Method Detail |
public Class getPersistentClass()
FieldChangeMap belongs
FieldChangeMap belongspublic Object getOid()
Persistent to which the field values in this FieldMap applypublic boolean isMapFor(Persistent obj)
FieldChangeMap holds field values for a given Persistent object.
obj - the persistent object to checkpublic Object getOldFieldValue(PersistentField field)
FieldChangeMap
field - the field for which a value is required
hasFieldValue(com.ashridgetech.prevdb.client.PersistentField)public Object getNewFieldValue(PersistentField field)
FieldChangeMap
field - the field for which a value is required
hasFieldValue(com.ashridgetech.prevdb.client.PersistentField)
public void setFieldValues(PersistentField field,
Object oldValue,
Object newValue)
FieldChangeMap
field - the field for which a value is to be set
#getOldFieldValuepublic FieldMap getOldFieldMap()
FieldMap of old values.
Note: the FieldMap returned is not copied, so it should not
be modified by the caller
public FieldMap getNewFieldMap()
FieldMap of new values.
Note: the FieldMap returned is not copied, so it should not
be modified by the caller
public boolean hasFieldValue(PersistentField field)
FieldChangeMap has a value for a particular field
field - the field for which a value is required
true if this FieldChangeMap has a value for fieldpublic Set getFields()
FieldChangeMap
PersistentField objectspublic String toString()
toString in class Object
|
|||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||