|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
public interface ObjectStorePersistence
| Method Summary | |
|---|---|
CreateObjectCommand |
createCreateObjectCommand(NakedObject object)
Makes a naked object persistent. |
DestroyObjectCommand |
createDestroyObjectCommand(NakedObject object)
Removes the specified object from the object store. |
SaveObjectCommand |
createSaveObjectCommand(NakedObject object)
Persists the specified object's state. |
void |
execute(java.util.List<PersistenceCommand> commands)
|
NakedObject[] |
getInstances(PersistenceQuery persistenceQuery)
|
NakedObject |
getObject(Oid oid,
NakedObjectSpecification hint)
Retrieves the object identified by the specified OID from the object store. |
Oid |
getOidForService(java.lang.String name)
Returns the OID for the adapted service. |
boolean |
hasInstances(NakedObjectSpecification specification)
|
boolean |
isFixturesInstalled()
Determine if the object store has been initialized with its set of start up objects. |
void |
registerService(java.lang.String name,
Oid oid)
|
void |
reset()
TODO: move to PersistenceSessionFactory ?? |
void |
resolveField(NakedObject object,
NakedObjectAssociation field)
Called by the resolveEagerly method in NakedObjectManager. |
void |
resolveImmediately(NakedObject object)
Called by the resolveImmediately method in NakedObjectManager. |
| Methods inherited from interface org.nakedobjects.metamodel.commons.debug.DebugInfo |
|---|
debugData, debugTitle |
| Methods inherited from interface org.nakedobjects.metamodel.commons.component.SessionScopedComponent |
|---|
close, open |
| Methods inherited from interface org.nakedobjects.metamodel.commons.component.NamedComponent |
|---|
name |
| Method Detail |
|---|
boolean isFixturesInstalled()
This method is called only once after the #init() has been called. If it returns false
then the framework will run the fixtures to initialise the object store.
void reset()
PersistenceSessionFactory ??
CreateObjectCommand createCreateObjectCommand(NakedObject object)
setOid method). The object, should also be added to the cache as the object is
implicitly 'in use'.
If the object has any associations then each of these, where they aren't already persistent, should also be made persistent by recursively calling this method.
If the object to be persisted is a collection, then each element of that collection, that is not already persistent, should be made persistent by recursively calling this method.
SaveObjectCommand createSaveObjectCommand(NakedObject object)
DestroyObjectCommand createDestroyObjectCommand(NakedObject object)
void execute(java.util.List<PersistenceCommand> commands)
NakedObject getObject(Oid oid,
NakedObjectSpecification hint)
Assuming that the object is not cached then the data for the object should be retreived from the
persistence mechanism and the object recreated (as describe previously). The specified OID should then
be assigned to the recreated object by calling its
If the persistence mechanism does not known of an object with the specified Oid then a
ObjectNotFoundException should be thrown.
Returns the stored NakedObject object .
NakedObject that has the specified Oid.
ObjectNotFoundException - when no object corresponding to the oid can be foundNakedObject[] getInstances(PersistenceQuery persistenceQuery)
boolean hasInstances(NakedObjectSpecification specification)
void resolveField(NakedObject object,
NakedObjectAssociation field)
PersistenceSessionContainer.resolveField(NakedObject, NakedObjectAssociation)void resolveImmediately(NakedObject object)
PersistenceSessionContainer.resolveImmediately(NakedObject)
void registerService(java.lang.String name,
Oid oid)
Oid getOidForService(java.lang.String name)
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||