org.nakedobjects.plugins.xml.objectstore
Class XmlObjectStore

java.lang.Object
  extended by org.nakedobjects.plugins.xml.objectstore.XmlObjectStore
All Implemented Interfaces:
Component, NamedComponent, SessionScopedComponent, DebugInfo, ObjectStore, ObjectStorePersistence, ObjectStoreTransactionManagement

public class XmlObjectStore
extends java.lang.Object
implements ObjectStore


Constructor Summary
XmlObjectStore(DataManager dataManager, ServiceManager serviceManager)
           
XmlObjectStore(NakedObjectConfiguration configuration)
           
 
Method Summary
 void abortTransaction()
           
 void close()
           
 CreateObjectCommand createCreateObjectCommand(NakedObject object)
           
 DestroyObjectCommand createDestroyObjectCommand(NakedObject object)
           
 SaveObjectCommand createSaveObjectCommand(NakedObject object)
           
 void debugData(DebugString debug)
           
 java.lang.String debugTitle()
           
 void endTransaction()
           
 void execute(java.util.List<PersistenceCommand> commands)
           
 NakedObject[] getInstances(PersistenceQuery persistenceQuery)
           
 NakedObject getObject(Oid oid, NakedObjectSpecification hint)
           
 Oid getOidForService(java.lang.String name)
           
protected static PersistenceSession getPersistenceSession()
           
protected static SpecificationLoader getSpecificationLoader()
           
 boolean hasInstances(NakedObjectSpecification cls)
           
 boolean isFixturesInstalled()
           
 java.lang.String name()
           
 void open()
           
 void registerService(java.lang.String name, Oid oid)
           
 void reset()
           
 void resolveField(NakedObject object, NakedObjectAssociation field)
           
 void resolveImmediately(NakedObject object)
           
 void setClock(Clock clock)
          Set the clock used to generate sequence numbers and last changed dates for version objects.
 void startTransaction()
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

XmlObjectStore

public XmlObjectStore(NakedObjectConfiguration configuration)

XmlObjectStore

public XmlObjectStore(DataManager dataManager,
                      ServiceManager serviceManager)
Method Detail

name

public java.lang.String name()
Specified by:
name in interface NamedComponent

close

public void close()
Specified by:
close in interface SessionScopedComponent

reset

public void reset()
Specified by:
reset in interface ObjectStorePersistence

hasInstances

public boolean hasInstances(NakedObjectSpecification cls)
Specified by:
hasInstances in interface ObjectStorePersistence

open

public void open()
          throws ObjectPersistenceException
Specified by:
open in interface SessionScopedComponent
Throws:
ObjectPersistenceException

isFixturesInstalled

public boolean isFixturesInstalled()
Specified by:
isFixturesInstalled in interface ObjectStorePersistence

startTransaction

public void startTransaction()
Specified by:
startTransaction in interface ObjectStoreTransactionManagement

endTransaction

public void endTransaction()
Specified by:
endTransaction in interface ObjectStoreTransactionManagement

abortTransaction

public void abortTransaction()
Specified by:
abortTransaction in interface ObjectStoreTransactionManagement

createCreateObjectCommand

public CreateObjectCommand createCreateObjectCommand(NakedObject object)
Specified by:
createCreateObjectCommand in interface ObjectStorePersistence

createSaveObjectCommand

public SaveObjectCommand createSaveObjectCommand(NakedObject object)
Specified by:
createSaveObjectCommand in interface ObjectStorePersistence

createDestroyObjectCommand

public DestroyObjectCommand createDestroyObjectCommand(NakedObject object)
Specified by:
createDestroyObjectCommand in interface ObjectStorePersistence

execute

public void execute(java.util.List<PersistenceCommand> commands)
Specified by:
execute in interface ObjectStorePersistence
Specified by:
execute in interface ObjectStoreTransactionManagement

getObject

public NakedObject getObject(Oid oid,
                             NakedObjectSpecification hint)
Specified by:
getObject in interface ObjectStorePersistence

resolveField

public void resolveField(NakedObject object,
                         NakedObjectAssociation field)
Specified by:
resolveField in interface ObjectStorePersistence

resolveImmediately

public void resolveImmediately(NakedObject object)
Specified by:
resolveImmediately in interface ObjectStorePersistence

getInstances

public NakedObject[] getInstances(PersistenceQuery persistenceQuery)
Specified by:
getInstances in interface ObjectStorePersistence

getOidForService

public Oid getOidForService(java.lang.String name)
Specified by:
getOidForService in interface ObjectStorePersistence

registerService

public void registerService(java.lang.String name,
                            Oid oid)
Specified by:
registerService in interface ObjectStorePersistence

debugData

public void debugData(DebugString debug)
Specified by:
debugData in interface DebugInfo

debugTitle

public java.lang.String debugTitle()
Specified by:
debugTitle in interface DebugInfo

setClock

public void setClock(Clock clock)
Set the clock used to generate sequence numbers and last changed dates for version objects.


getSpecificationLoader

protected static SpecificationLoader getSpecificationLoader()

getPersistenceSession

protected static PersistenceSession getPersistenceSession()


Copyright © 2001-2009 Naked Objects Group Ltd.. All Rights Reserved.