|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
public interface StateManager
StateManager for a persistable object. Based around the JDO PersistenceCapable contract. Makes the assumption that a StateManager corresponds to ONE persistable object.
| Field Summary |
|---|
| Fields inherited from interface org.datanucleus.state.ObjectProvider |
|---|
EMBEDDED_COLLECTION_ELEMENT_PC, EMBEDDED_MAP_KEY_PC, EMBEDDED_MAP_VALUE_PC, EMBEDDED_PC, ORIGINAL_FIELD_VALUE_KEY_PREFIX, PC |
| Method Summary | |
|---|---|
void |
checkInheritance(FieldValues fv)
Look to the database to determine which class this object is. |
void |
initialiseForCachedPC(CachedPC cachedPC,
Object id)
Initialise the ObjectProvider, assigning the specified id to the object. |
void |
initialiseForDetached(Object pc,
Object id,
Object version)
Initialises the ObjectProvider to manage a persistable object in detached state. |
void |
initialiseForEmbedded(Object pc,
boolean copyPc)
Initialises a state manager to manage a PersistenceCapable instance that will be EMBEDDED/SERIALISED into another PersistenceCapable object. |
void |
initialiseForHollow(Object id,
FieldValues fv,
Class pcClass)
Initialises a state manager to manage a hollow instance having the given object ID and the given (optional) field values. |
void |
initialiseForHollowAppId(FieldValues fv,
Class pcClass)
Initialises a state manager to manage a HOLLOW / P_CLEAN instance having the given FieldValues. |
void |
initialiseForHollowPreConstructed(Object id,
Object pc)
Initialises a state manager to manage the given hollow instance having the given object ID. |
void |
initialiseForPersistentClean(Object id,
Object pc)
Initialises a state manager to manage the passed persistent instance having the given object ID. |
void |
initialiseForPersistentNew(Object pc,
FieldValues preInsertChanges)
Initialises a state manager to manage a transient instance that is becoming newly persistent. |
void |
initialiseForPNewToBeDeleted(Object pc)
Initialises the StateManager to manage a PersistenceCapable object that is not persistent but that is about to be deleted. |
void |
initialiseForTransactionalTransient(Object pc)
Initialises a state manager to manage a Transactional Transient instance. |
| Method Detail |
|---|
void initialiseForHollow(Object id,
FieldValues fv,
Class pcClass)
id - the identity of the object.fv - the initial field values of the object (optional)pcClass - Class of the object that this will manage the state for
void initialiseForHollowAppId(FieldValues fv,
Class pcClass)
fv - the initial field values of the object.pcClass - Class of the object that this will manage the state for
void initialiseForHollowPreConstructed(Object id,
Object pc)
initialiseForHollow(java.lang.Object, org.datanucleus.store.FieldValues, java.lang.Class) method, this method does not create a new instance and instead
takes a pre-constructed instance.
id - the identity of the object.pc - the object to be managed.
void initialiseForPersistentClean(Object id,
Object pc)
id - the identity of the object.pc - The object to be managed
void initialiseForEmbedded(Object pc,
boolean copyPc)
pc - The PersistenceCapable to manage (see copyPc also)copyPc - Whether the SM should manage a copy of the passed PC or that one
void initialiseForPersistentNew(Object pc,
FieldValues preInsertChanges)
This constructor is used for assigning state managers to existing instances that are transitioning to a persistent state.
pc - the instance being make persistent.preInsertChanges - Any changes to make before insertingvoid initialiseForTransactionalTransient(Object pc)
This constructor is used for assigning state managers to Transient instances that are transitioning to a transient clean state.
pc - the instance being make persistent.
void initialiseForDetached(Object pc,
Object id,
Object version)
pc - the detach object.id - the identity of the object.version - the detached version
void initialiseForCachedPC(CachedPC cachedPC,
Object id)
cachedPC - Cache object for persistable object from L2 cacheid - Id to assign to the persistable objectvoid initialiseForPNewToBeDeleted(Object pc)
pc - the object to deletevoid checkInheritance(FieldValues fv)
fv - the initial field values of the object.
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||