|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.jpox.resource.PersistenceManagerImpl
public class PersistenceManagerImpl
Implementation of the PersistenceManager for use in JCA environments.
An application handle associated to the ManagedConnectionImpl.
| Field Summary | |
|---|---|
protected static Localiser |
LOCALISER
Localisation utility for output messages |
| Constructor Summary | |
|---|---|
PersistenceManagerImpl(ManagedConnectionImpl mc)
Constructor. |
|
| Method Summary | |
|---|---|
void |
addConnectionEventListener(javax.resource.spi.ConnectionEventListener listener)
|
void |
addInstanceLifecycleListener(javax.jdo.listener.InstanceLifecycleListener listener,
java.lang.Class[] classes)
JDO 2.0 spec 12.15 "LifecycleListeners". |
void |
addQueryResult(QueryResult queryResult)
|
void |
addQueryRun(java.lang.String singleStringQuery)
|
void |
addStateManager(StateManager sm)
|
java.lang.Object |
attachCopy(java.lang.Object pc,
boolean embedded)
Method to attach a persistent object. |
void |
checkConsistency()
Method to check the consistency of the cache. |
void |
clearDirty(StateManager sm)
|
void |
close()
Method to close the Persistence Manager. |
javax.resource.cci.Interaction |
createInteraction()
|
javax.jdo.Transaction |
currentTransaction()
Accessor for the current transaction |
void |
deletePersistent(java.lang.Object pc)
JDO method to delete a Persistence Capable object |
void |
deletePersistentAll(java.util.Collection pcs)
JDO method to delete a Collection of Persistence Capable objects |
void |
deletePersistentAll(java.lang.Object[] pcs)
JDO method to delete an array of Persistence Capable objects |
java.lang.Object |
detachCopy(java.lang.Object pc)
Detach the specified object from the PersistenceManager. |
java.util.Collection |
detachCopyAll(java.util.Collection pcs)
Detach the specified objects from the PersistenceManager. |
java.lang.Object[] |
detachCopyAll(java.lang.Object[] pcs)
Detach the specified objects from the PersistenceManager. |
java.lang.Object |
detachCopyInternal(java.lang.Object pc,
FetchPlanState state)
Method to detach a copy of the passed object using the detached state. |
void |
detachInternal(java.lang.Object pc,
FetchPlanState state)
Detach the specified object from the PersistenceManager. |
void |
dump(java.lang.Object obj,
java.io.PrintWriter out)
Method to dump to output an object for diagnostic purposes. |
void |
enlistInTransaction(StateManager sm)
|
void |
evict(java.lang.Object o)
Method to evict an object |
void |
evictAll()
Method to evict all objects from the PM. |
void |
evictAll(java.util.Collection os)
Method to evict all of the specified objects from the PM. |
void |
evictAll(java.lang.Object[] os)
Method to evict an array of objects |
void |
evictFromTransaction(StateManager sm)
|
StateManager |
findStateManager(javax.jdo.spi.PersistenceCapable pc)
|
void |
flush()
This method flushes all dirty, new, and deleted instances to the datastore. |
ClassLoaderResolver |
getClassLoaderResolver()
Accessor for the ClassLoaderResolver |
java.sql.Connection |
getConnection(boolean forWriting,
boolean forQuery)
Accessor for a connection to the datastore. |
java.sql.Connection |
getConnection(boolean forWriting,
boolean forQuery,
boolean useOpenedConnection)
Accessor for the connection to the datasource. |
javax.jdo.datastore.JDOConnection |
getDataStoreConnection()
(non-Javadoc) |
boolean |
getDetachAllOnCommit()
Accessor for whether to detach objects on commit of the txn. |
boolean |
getDetachOnClose()
Accessor for whether to detach objects on close of the PM's |
javax.jdo.Extent |
getExtent(java.lang.Class cls)
Accessor for the extent of a candidate class. |
javax.jdo.Extent |
getExtent(java.lang.Class cls,
boolean subclasses)
Accessor for the extent of a candidate class. |
javax.jdo.FetchPlan |
getFetchPlan()
Acessor for the current FetchPlan |
boolean |
getIgnoreCache()
Accessor for whether to ignore the cache or not |
javax.resource.cci.LocalTransaction |
getLocalTransaction()
Accessor for the local transaction. |
javax.resource.cci.ConnectionMetaData |
getMetaData()
Accessor for Meta-Data. |
MetaDataManager |
getMetaDataManager()
Accessor for the MetaData Manager. |
boolean |
getMultithreaded()
Accessor for the multithreaded capability of the manager |
java.lang.Object |
getObjectByAID(java.lang.Class pcClass,
FieldValues fv,
boolean ignoreCache,
boolean checkInheritance)
Accessor for the StateManager of an object given the object AID. |
java.lang.Object |
getObjectById(java.lang.Class cls,
java.lang.Object key)
|
java.lang.Object |
getObjectById(java.lang.Object id)
Accessor for an object given its id. |
java.lang.Object |
getObjectById(java.lang.Object id,
boolean validate)
Accessor for an object given its id. |
java.lang.Object |
getObjectById(java.lang.Object id,
boolean validate,
boolean checkInheritance)
Accessor for an object given the object id. |
java.lang.Object |
getObjectById(java.lang.Object id,
FieldValues fv)
|
java.lang.Object |
getObjectById(java.lang.Object id,
FieldValues fv,
java.lang.Class clazz,
boolean ignoreCache)
Accessor for an object given the object id. |
java.lang.Object |
getObjectId(java.lang.Object pc)
Accessor for the id of an object. |
java.lang.Class |
getObjectIdClass(java.lang.Class clazz)
Retrieve the class for the objectid |
java.util.Collection |
getObjectsById(java.util.Collection oids)
|
java.util.Collection |
getObjectsById(java.util.Collection oids,
boolean validate)
|
java.lang.Object[] |
getObjectsById(java.lang.Object[] oids)
|
java.lang.Object[] |
getObjectsById(java.lang.Object[] oids,
boolean validate)
|
javax.jdo.PersistenceManagerFactory |
getPersistenceManagerFactory()
Retrieve the PersistenceManagerFactory for this manager |
PMFContext |
getPMFContext()
Gets the context which this PersistenceManager is running |
PersistenceManager |
getPMHandle()
Accessor for a handle to the Persistence Manager |
javax.resource.cci.ResultSetInfo |
getResultSetInfo()
|
javax.jdo.datastore.Sequence |
getSequence(java.lang.String sequenceName)
Accessor for a Sequence. |
StateManager |
getStateManagerById(java.lang.Object myID)
|
StoreManager |
getStoreManager()
Accessor for the Store Manager. |
java.lang.Object |
getTransactionalObjectId(java.lang.Object pc)
|
java.lang.Object |
getUserObject()
The application might manage PersistenceManager instances by using an associated object for bookkeeping purposes. |
java.lang.Object |
getUserObject(java.lang.Object key)
Method to get a user object from the PersistenceManager. |
boolean |
hasQueryRun(java.lang.String singleStringQuery)
|
void |
hereIsStateManager(StateManager sm,
javax.jdo.spi.PersistenceCapable pc)
|
boolean |
isClosed()
Accessor for whether the Persistence manager is closed. |
boolean |
isConnectionOpen()
Checks whether a connection to the datasource is open. |
boolean |
isDelayDatastoreOperationsEnabled()
Whether the datastore operations are delayed until commit. |
boolean |
isInserting(javax.jdo.spi.PersistenceCapable pc)
Tests whether this object is being inserted. |
void |
makeNontransactional(java.lang.Object pc)
Make a Persistence-Capable object non-transactional |
void |
makeNontransactionalAll(java.util.Collection pcs)
Make a Collection of Persistence-Capable objects non-transactional |
void |
makeNontransactionalAll(java.lang.Object[] pcs)
Make an array of Persistence-Capable objects non-transactional |
java.lang.Object |
makePersistent(java.lang.Object pc)
Method to make an object persistent. |
java.util.Collection |
makePersistentAll(java.util.Collection pcs)
Make a Collection of Persistence Capable objects persistent |
java.lang.Object[] |
makePersistentAll(java.lang.Object[] pcs)
Make an array of Persistent Capable objects persistent |
java.lang.Object |
makePersistentInternal(java.lang.Object obj,
FieldValues preInsertChanges)
Method to make an object persistent during the persisting process. |
void |
makeTransactional(java.lang.Object pc)
Make a Persistence-Capable object transient |
void |
makeTransactionalAll(java.util.Collection pcs)
Make a collection of PersistenceCapable objects transactional |
void |
makeTransactionalAll(java.lang.Object[] pcs)
Make an array of Persistence-Capable objects transactional |
void |
makeTransient(java.lang.Object pc)
Make a Persistence-Capable object transient |
void |
makeTransient(java.lang.Object pc,
boolean useFetchPlan)
Make a Persistence-Capable object transient , optionally using the fetch plan. |
void |
makeTransientAll(java.util.Collection pcs)
Make a Collection of Persistence-Capable objects transient |
void |
makeTransientAll(java.util.Collection pcs,
boolean useFetchPlan)
Make a Collection of Persistence-Capable objects transient |
void |
makeTransientAll(java.lang.Object[] pcs)
Make an array of Persistence-Capable objects transient |
void |
makeTransientAll(java.lang.Object[] pcs,
boolean useFetchPlan)
Make an array of Persistence-Capable objects transient |
void |
makeTransientInternal(java.lang.Object obj,
FetchPlanState state)
Method to make an object transient. |
void |
markDirty(StateManager sm)
|
java.lang.Object |
newInstance(java.lang.Class persistenceCapable)
Method to create an instance of an interface or abstract class |
javax.jdo.Query |
newNamedQuery(java.lang.Class cls,
java.lang.String queryName)
Accessor for a new named query. |
java.lang.Object |
newObjectIdInstance(java.lang.Class pcClass,
java.lang.Object key)
|
java.lang.Object |
newObjectIdInstance(java.lang.Class clazz,
java.lang.String str)
|
javax.jdo.Query |
newQuery()
Accessor for a new query. |
javax.jdo.Query |
newQuery(java.lang.Class cls)
Accessor for a new query using this candidate class. |
javax.jdo.Query |
newQuery(java.lang.Class cls,
java.util.Collection cln)
Accessor for a new query. |
javax.jdo.Query |
newQuery(java.lang.Class cls,
java.util.Collection cln,
java.lang.String filter)
Accessor for a new query. |
javax.jdo.Query |
newQuery(java.lang.Class cls,
java.lang.String filter)
Accessor for a new query. |
javax.jdo.Query |
newQuery(javax.jdo.Extent ext)
Accessor for a new query based on the provided extent. |
javax.jdo.Query |
newQuery(javax.jdo.Extent cln,
java.lang.String filter)
Accessor for a new query. |
javax.jdo.Query |
newQuery(java.lang.Object obj)
Accessor for a new query. |
javax.jdo.Query |
newQuery(java.lang.String query)
Accessor for a single-string query. |
javax.jdo.Query |
newQuery(java.lang.String language,
java.lang.Object query)
Accessor for a new query in the specified query language etc. |
void |
notifyLifecycleListenersForEvent(java.lang.Object obj,
int lifecycleEventType,
java.lang.Object otherObj)
Utility to notify the lifecycle listeners for an event on an object. |
void |
putObjectIntoCache(StateManager sm,
boolean level1,
boolean level2)
Method to put an object into the respective cache. |
java.lang.Object |
putUserObject(java.lang.Object key,
java.lang.Object value)
Method to put a user object into the PersistenceManager. |
void |
refresh(java.lang.Object o)
Method to refresh an object |
void |
refreshAll()
Method to refresh all objects in the Persistence Manager. |
void |
refreshAll(java.util.Collection os)
Method to refresh a collection of objects. |
void |
refreshAll(javax.jdo.JDOException exc)
Method to refresh objects that failed verification in a JDOException |
void |
refreshAll(java.lang.Object[] os)
Method to refresh an array of objects. |
void |
releaseConnection(java.sql.Connection conn)
Method to release a connection. |
void |
removeAllInstanceLifecycleListeners()
|
void |
removeConnectionEventListener(javax.resource.spi.ConnectionEventListener listener)
|
void |
removeInstanceLifecycleListener(javax.jdo.listener.InstanceLifecycleListener listener)
JDO 2.0 spec 12.15 "LifecycleListeners". |
void |
removeObjectFromCache(javax.jdo.spi.PersistenceCapable pc,
java.lang.Object id,
boolean level1,
boolean level2)
Method to remove an object from the respective cache. |
void |
removeQueryResult(QueryResult queryResult)
|
void |
removeQueryRun(java.lang.String singleStringQuery)
|
void |
removeStateManager(StateManager sm)
|
java.lang.Object |
removeUserObject(java.lang.Object key)
Method to remove a user object from the PersistenceManager. |
void |
replaceObjectId(javax.jdo.spi.PersistenceCapable pc,
java.lang.Object oldID,
java.lang.Object newID)
Replace the previous object id for a PC object to a new |
void |
retrieve(java.lang.Object o)
Method to retrieve an object |
void |
retrieve(java.lang.Object o,
boolean fgOnly)
Method to retrieve an object |
void |
retrieveAll(java.util.Collection pcs)
Retrieve a Collection of Persistence-Capable objects |
void |
retrieveAll(java.util.Collection pcs,
boolean fgOnly)
Retrieve field values of instances from the store. |
void |
retrieveAll(java.lang.Object[] pcs)
Retrieve an array of Persistence-Capable objects |
void |
retrieveAll(java.lang.Object[] pcs,
boolean fgOnly)
Retrieve field values of instances from the store. |
void |
setDetachAllOnCommit(boolean detach)
Mutator for whether to detach all objects on commit of the txn. |
void |
setDetachOnClose(boolean detach)
Mutator for whether to detach objects on close of the PM's |
void |
setIgnoreCache(boolean ignore)
Mutator for whether to ignore the cache or not |
void |
setMultithreaded(boolean multithreaded)
Mutator for the multithreaded capability of the manager |
void |
setUserObject(java.lang.Object obj)
The application might manage PersistenceManager instances by using an associated object for bookkeeping purposes. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
protected static final Localiser LOCALISER
| Constructor Detail |
|---|
public PersistenceManagerImpl(ManagedConnectionImpl mc)
mc - The connection implementation.| Method Detail |
|---|
public void dump(java.lang.Object obj,
java.io.PrintWriter out)
obj - The object to dumpout - The PrintWriter to usePersistenceManager.dump(java.lang.Object, java.io.PrintWriter)
public java.lang.Object getObjectById(java.lang.Object id,
FieldValues fv,
java.lang.Class clazz,
boolean ignoreCache)
id - Id of the object.fv - Field values for the objectclazz - Class name of the objectignoreCache - true if it must ignore the cache
public java.lang.Object getObjectByAID(java.lang.Class pcClass,
FieldValues fv,
boolean ignoreCache,
boolean checkInheritance)
pcClass - fv - ignoreCache - true if it must ignore the cache*checkInheritance - Whether look to the database to determine which
class this object is. This parameter is a hint. Set false, if it's
already determined the correct pcClass for this pc "object" in a certain
level in the hierarchy. Set to true and it will look to the database.
public javax.resource.cci.LocalTransaction getLocalTransaction()
throws javax.resource.ResourceException
getLocalTransaction in interface javax.resource.cci.Connectionjavax.resource.ResourceException - Thrown when an error occurs
public javax.resource.cci.ConnectionMetaData getMetaData()
throws javax.resource.ResourceException
getMetaData in interface javax.resource.cci.Connectionjavax.resource.ResourceException -
public javax.resource.cci.Interaction createInteraction()
throws javax.resource.ResourceException
createInteraction in interface javax.resource.cci.Connectionjavax.resource.ResourceException -
public javax.resource.cci.ResultSetInfo getResultSetInfo()
throws javax.resource.ResourceException
getResultSetInfo in interface javax.resource.cci.Connectionjavax.resource.ResourceException - public void close()
close in interface javax.jdo.PersistenceManagerclose in interface javax.resource.cci.Connectionpublic boolean isClosed()
isClosed in interface javax.jdo.PersistenceManagerpublic void setDetachOnClose(boolean detach)
detach - Whether to detach objects on close of the PM.public boolean getDetachOnClose()
public void setDetachAllOnCommit(boolean detach)
setDetachAllOnCommit in interface javax.jdo.PersistenceManagerdetach - Whether to detach objects on commit of the txn.public boolean getDetachAllOnCommit()
getDetachAllOnCommit in interface javax.jdo.PersistenceManagerpublic boolean isDelayDatastoreOperationsEnabled()
public void refresh(java.lang.Object o)
refresh in interface javax.jdo.PersistenceManagero - Object to refresh
public void retrieve(java.lang.Object o,
boolean fgOnly)
retrieve in interface javax.jdo.PersistenceManagero - Object to retrievefgOnly - Whether to include only fields in current fetch grouppublic void retrieve(java.lang.Object o)
retrieve in interface javax.jdo.PersistenceManagero - Object to retrievepublic void retrieveAll(java.util.Collection pcs)
retrieveAll in interface javax.jdo.PersistenceManagerpcs - Collection of Persistence-Capable objectspublic void retrieveAll(java.lang.Object[] pcs)
retrieveAll in interface javax.jdo.PersistenceManagerpcs - Array of Persistence-Capable objects
public void retrieveAll(java.lang.Object[] pcs,
boolean fgOnly)
PersistenceManager that the application intends to use
the instances, and their field values should be retrieved. The fields
in the current fetch group must be retrieved, and the implementation
might retrieve more fields than the current fetch-group.
The PersistenceManager might use policy information
about the class to retrieve associated instances.
retrieveAll in interface javax.jdo.PersistenceManagerpcs - the instancesfgOnly - whether to retrieve only the current fetch-group fields
public void retrieveAll(java.util.Collection pcs,
boolean fgOnly)
PersistenceManager that the application intends to use
the instances, and their field values should be retrieved. The fields
in the current fetch group must be retrieved, and the implementation
might retrieve more fields than the current fetch-group.
The PersistenceManager might use policy information
about the class to retrieve associated instances.
retrieveAll in interface javax.jdo.PersistenceManagerpcs - the instancesfgOnly - whether to retrieve only the current fetch group fieldspublic javax.jdo.Transaction currentTransaction()
currentTransaction in interface javax.jdo.PersistenceManagerpublic void evict(java.lang.Object o)
evict in interface javax.jdo.PersistenceManagero - Object to evictpublic void evictAll(java.lang.Object[] os)
evictAll in interface javax.jdo.PersistenceManageros - Array of objects to evictpublic void evictAll(java.util.Collection os)
evictAll in interface javax.jdo.PersistenceManageros - Collection of objects to evictpublic void evictAll()
evictAll in interface javax.jdo.PersistenceManagerpublic void refreshAll(java.lang.Object[] os)
refreshAll in interface javax.jdo.PersistenceManageros - Array of objects to refreshpublic void refreshAll(java.util.Collection os)
refreshAll in interface javax.jdo.PersistenceManageros - Collection of objects to refreshpublic void refreshAll(javax.jdo.JDOException exc)
refreshAll in interface javax.jdo.PersistenceManagerexc - Exception containing objects that failed verificationpublic void refreshAll()
refreshAll in interface javax.jdo.PersistenceManagerpublic javax.jdo.Query newQuery()
newQuery in interface javax.jdo.PersistenceManagerpublic javax.jdo.Query newQuery(java.lang.Object obj)
newQuery in interface javax.jdo.PersistenceManagerobj - object
public javax.jdo.Query newQuery(java.lang.String query)
newQuery in interface javax.jdo.PersistenceManagerquery - The single-string query
public javax.jdo.Query newQuery(java.lang.String language,
java.lang.Object query)
newQuery in interface javax.jdo.PersistenceManagerlanguage - The query languagequery - The query definition
public javax.jdo.Query newQuery(java.lang.Class cls)
newQuery in interface javax.jdo.PersistenceManagercls - The candidate class to use.
public javax.jdo.Query newQuery(javax.jdo.Extent ext)
newQuery in interface javax.jdo.PersistenceManagerext - The extent to use
public javax.jdo.Query newQuery(java.lang.Class cls,
java.util.Collection cln)
newQuery in interface javax.jdo.PersistenceManagercls - The candidate class.cln - The collection to use.
public javax.jdo.Query newQuery(java.lang.Class cls,
java.lang.String filter)
newQuery in interface javax.jdo.PersistenceManagercls - The candidate classfilter - The filter to use
public javax.jdo.Query newQuery(java.lang.Class cls,
java.util.Collection cln,
java.lang.String filter)
newQuery in interface javax.jdo.PersistenceManagercls - The candidate classcln - The collectionfilter - The filter to use
public javax.jdo.Query newQuery(javax.jdo.Extent cln,
java.lang.String filter)
newQuery in interface javax.jdo.PersistenceManagercln - The collectionfilter - The filter to use
public javax.jdo.Query newNamedQuery(java.lang.Class cls,
java.lang.String queryName)
newNamedQuery in interface javax.jdo.PersistenceManagercls - The candidate classqueryName - The name of the query
public javax.jdo.Extent getExtent(java.lang.Class cls,
boolean subclasses)
getExtent in interface javax.jdo.PersistenceManagercls - The candidate classsubclasses - Whether to include subclasses
public javax.jdo.Extent getExtent(java.lang.Class cls)
getExtent in interface javax.jdo.PersistenceManagercls - The candidate class
public javax.jdo.FetchPlan getFetchPlan()
getFetchPlan in interface javax.jdo.PersistenceManagerpublic java.lang.Object getObjectById(java.lang.Object id)
getObjectById in interface javax.jdo.PersistenceManagerid - Id of the object.
public java.lang.Object getObjectById(java.lang.Object id,
boolean validate)
getObjectById in interface javax.jdo.PersistenceManagerid - Id of the object.validate - Whether to validate the object before returning it
public java.util.Collection getObjectsById(java.util.Collection oids)
getObjectsById in interface javax.jdo.PersistenceManagerpublic java.lang.Object[] getObjectsById(java.lang.Object[] oids)
getObjectsById in interface javax.jdo.PersistenceManager
public java.util.Collection getObjectsById(java.util.Collection oids,
boolean validate)
getObjectsById in interface javax.jdo.PersistenceManager
public java.lang.Object[] getObjectsById(java.lang.Object[] oids,
boolean validate)
getObjectsById in interface javax.jdo.PersistenceManager
public java.lang.Object getObjectById(java.lang.Class cls,
java.lang.Object key)
getObjectById in interface javax.jdo.PersistenceManager
public java.lang.Object newObjectIdInstance(java.lang.Class pcClass,
java.lang.Object key)
newObjectIdInstance in interface javax.jdo.PersistenceManager
public java.lang.Object getObjectById(java.lang.Object id,
boolean validate,
boolean checkInheritance)
id - Id of the object.validate - Whether to validate the object statecheckInheritance - Whether look to the database to determine which
class this object is. This parameter is a hint. Set false, if it's
already determined the correct pcClass for this pc "object" in a certain
level in the hierarchy. Set to true and it will look to the database.
public java.lang.Object getObjectId(java.lang.Object pc)
getObjectId in interface javax.jdo.PersistenceManagerpc - The object
public java.lang.Object getTransactionalObjectId(java.lang.Object pc)
getTransactionalObjectId in interface javax.jdo.PersistenceManagerpc -
public java.lang.Object newObjectIdInstance(java.lang.Class clazz,
java.lang.String str)
clazz - str - public java.lang.Object newInstance(java.lang.Class persistenceCapable)
newInstance in interface javax.jdo.PersistenceManagerpersistenceCapable - interface/abstract class declared in metadata
public java.lang.Object makePersistentInternal(java.lang.Object obj,
FieldValues preInsertChanges)
obj - The object to persistpreInsertChanges - Changes to make before inserting
public java.lang.Object makePersistent(java.lang.Object pc)
makePersistent in interface javax.jdo.PersistenceManagerpc - The object to persistpublic java.lang.Object[] makePersistentAll(java.lang.Object[] pcs)
makePersistentAll in interface javax.jdo.PersistenceManagerpcs - Array of Persistent Capable objectspublic java.util.Collection makePersistentAll(java.util.Collection pcs)
makePersistentAll in interface javax.jdo.PersistenceManagerpcs - Collection of Persistence Capable objectspublic void deletePersistent(java.lang.Object pc)
deletePersistent in interface javax.jdo.PersistenceManagerpc - Persistence Capable objectpublic void deletePersistentAll(java.lang.Object[] pcs)
deletePersistentAll in interface javax.jdo.PersistenceManagerpcs - Array of Persistence Capable objectspublic void deletePersistentAll(java.util.Collection pcs)
deletePersistentAll in interface javax.jdo.PersistenceManagerpcs - Collection of Persistence Capable objects
public void makeTransient(java.lang.Object pc,
boolean useFetchPlan)
makeTransient in interface javax.jdo.PersistenceManagerpc - Persistence-Capable objectuseFetchPlan - Whether to use the fetch plan
public void makeTransientAll(java.lang.Object[] pcs,
boolean useFetchPlan)
makeTransientAll in interface javax.jdo.PersistenceManagerpcs - Array of Persistence-Capable objectsuseFetchPlan - Whether to use the fetch plan
public void makeTransientAll(java.util.Collection pcs,
boolean useFetchPlan)
makeTransientAll in interface javax.jdo.PersistenceManagerpcs - Collection of Persistence-Capable objectsuseFetchPlan - Whether to use the fetch planpublic void makeTransient(java.lang.Object pc)
makeTransient in interface javax.jdo.PersistenceManagerpc - Persistence-Capable objectpublic void makeTransientAll(java.lang.Object[] pcs)
makeTransientAll in interface javax.jdo.PersistenceManagerpcs - Array of Persistence-Capable objectspublic void makeTransientAll(java.util.Collection pcs)
makeTransientAll in interface javax.jdo.PersistenceManagerpcs - Collection of Persistence-Capable objects
public void makeTransientInternal(java.lang.Object obj,
FetchPlanState state)
obj - The object to persiststate - Object containing the state of the fetchplan processpublic void makeTransactional(java.lang.Object pc)
makeTransactional in interface javax.jdo.PersistenceManagerpc - Persistence-Capable objectpublic void makeTransactionalAll(java.lang.Object[] pcs)
makeTransactionalAll in interface javax.jdo.PersistenceManagerpcs - Array of Persistence-Capable objectspublic void makeTransactionalAll(java.util.Collection pcs)
makeTransactionalAll in interface javax.jdo.PersistenceManagerpcs - Collection of Persistence-Capable objectspublic void makeNontransactional(java.lang.Object pc)
makeNontransactional in interface javax.jdo.PersistenceManagerpc - Persistence-Capable objectpublic void makeNontransactionalAll(java.lang.Object[] pcs)
makeNontransactionalAll in interface javax.jdo.PersistenceManagerpcs - Array of Persistence-Capable objectspublic void makeNontransactionalAll(java.util.Collection pcs)
makeNontransactionalAll in interface javax.jdo.PersistenceManagerpcs - Collection of Persistence-Capable objects
public void detachInternal(java.lang.Object pc,
FetchPlanState state)
PersistenceManager.
pc - the instance to detachstate - State for the detachment processpublic java.lang.Object detachCopy(java.lang.Object pc)
PersistenceManager.
detachCopy in interface javax.jdo.PersistenceManagerpc - the instance to detach
detachCopyAll(Object[])
public java.lang.Object detachCopyInternal(java.lang.Object pc,
FetchPlanState state)
pc - The Objectstate - Detach state to use
public java.lang.Object[] detachCopyAll(java.lang.Object[] pcs)
PersistenceManager. The objects returned can be
manipulated and re-attached with
makePersistentAll(Object[]).
The detached instances will be
unmanaged copies of the specified parameters, and are suitable
for serialization and manipulation outside of a JDO
environment. When detaching instances, only fields in the
current FetchPlan will be traversed. Thus, to detach a
graph of objects, relations to other persistent instances must
either be in the default-fetch-group, or in the
current custom FetchPlan.
detachCopyAll in interface javax.jdo.PersistenceManagerpcs - the instances to detach
javax.jdo.JDOUserException - if any of the instances do notmakePersistentAll(Object[]),
getFetchPlan()public java.util.Collection detachCopyAll(java.util.Collection pcs)
PersistenceManager.
detachCopyAll in interface javax.jdo.PersistenceManagerpcs - the instances to detach
detachCopyAll(Object[])
public java.lang.Object attachCopy(java.lang.Object pc,
boolean embedded)
pc - The objectembedded - Whether the object is embedded
public java.lang.Object putUserObject(java.lang.Object key,
java.lang.Object value)
putUserObject in interface javax.jdo.PersistenceManagerkey - The key to store the user object undervalue - The object to store
public java.lang.Object getUserObject(java.lang.Object key)
getUserObject in interface javax.jdo.PersistenceManagerkey - The key to store the user object under
public java.lang.Object removeUserObject(java.lang.Object key)
removeUserObject in interface javax.jdo.PersistenceManagerkey - The key whose uder object is to be removed.
public void setUserObject(java.lang.Object obj)
setUserObject in interface javax.jdo.PersistenceManagerobj - User Objectpublic java.lang.Object getUserObject()
getUserObject in interface javax.jdo.PersistenceManagerpublic javax.jdo.PersistenceManagerFactory getPersistenceManagerFactory()
getPersistenceManagerFactory in interface javax.jdo.PersistenceManagerpublic java.lang.Class getObjectIdClass(java.lang.Class clazz)
getObjectIdClass in interface javax.jdo.PersistenceManagerclazz - The class to retrieve
public void setMultithreaded(boolean multithreaded)
setMultithreaded in interface javax.jdo.PersistenceManagermultithreaded - Whether to run multithreaded or notpublic boolean getMultithreaded()
getMultithreaded in interface javax.jdo.PersistenceManagerpublic void setIgnoreCache(boolean ignore)
setIgnoreCache in interface javax.jdo.PersistenceManagerignore - Whether to ignore the cache or notpublic boolean getIgnoreCache()
getIgnoreCache in interface javax.jdo.PersistenceManagerpublic StoreManager getStoreManager()
public MetaDataManager getMetaDataManager()
public java.sql.Connection getConnection(boolean forWriting,
boolean forQuery)
throws java.sql.SQLException
forWriting - Whether it is for writing toforQuery - Whether the connection is to be used by a query (i.e.JDOQUERY).
java.sql.SQLException - Thrown when an error occurs in obtaining it.
public java.sql.Connection getConnection(boolean forWriting,
boolean forQuery,
boolean useOpenedConnection)
throws java.sql.SQLException
forWriting - Whether the connection is read-only or read-write.forQuery - Whether the connection is to be used by a query (i.e.JDOQUERY).useOpenedConnection - whether to use an already opened connection, if one is opened.
java.sql.SQLExceptionpublic boolean isConnectionOpen()
public void releaseConnection(java.sql.Connection conn)
throws java.sql.SQLException
conn - The Connection to release.
java.sql.SQLException - Thrown when an error occurspublic void enlistInTransaction(StateManager sm)
public void evictFromTransaction(StateManager sm)
public void removeStateManager(StateManager sm)
public java.lang.Object getObjectById(java.lang.Object id,
FieldValues fv)
public StateManager findStateManager(javax.jdo.spi.PersistenceCapable pc)
public void hereIsStateManager(StateManager sm,
javax.jdo.spi.PersistenceCapable pc)
public void markDirty(StateManager sm)
public void flush()
flush in interface javax.jdo.PersistenceManagerpublic void checkConsistency()
checkConsistency in interface javax.jdo.PersistenceManagerpublic boolean isInserting(javax.jdo.spi.PersistenceCapable pc)
pc - the object to verify the status
public void clearDirty(StateManager sm)
public ClassLoaderResolver getClassLoaderResolver()
public PersistenceManager getPMHandle()
public void addStateManager(StateManager sm)
public StateManager getStateManagerById(java.lang.Object myID)
public PMFContext getPMFContext()
public javax.jdo.datastore.JDOConnection getDataStoreConnection()
getDataStoreConnection in interface javax.jdo.PersistenceManagerPersistenceManager.getDataStoreConnection()public javax.jdo.datastore.Sequence getSequence(java.lang.String sequenceName)
getSequence in interface javax.jdo.PersistenceManagersequenceName - Name of the sequence
public void notifyLifecycleListenersForEvent(java.lang.Object obj,
int lifecycleEventType,
java.lang.Object otherObj)
obj - The object that had the operation performed on itlifecycleEventType - The lifecycle eventotherObj - Other object involved in the event (if any)public void removeAllInstanceLifecycleListeners()
AbstractPersistenceManager.removeAllInstanceLifecycleListeners()
public void addInstanceLifecycleListener(javax.jdo.listener.InstanceLifecycleListener listener,
java.lang.Class[] classes)
addInstanceLifecycleListener in interface javax.jdo.PersistenceManagerlistener - The instance lifecycle listener to sends events toclasses - The classes that it is interested inpublic void removeInstanceLifecycleListener(javax.jdo.listener.InstanceLifecycleListener listener)
removeInstanceLifecycleListener in interface javax.jdo.PersistenceManagerlistener - The instance lifecycle listener to remove.public void addQueryResult(QueryResult queryResult)
public void removeQueryResult(QueryResult queryResult)
public void addQueryRun(java.lang.String singleStringQuery)
public boolean hasQueryRun(java.lang.String singleStringQuery)
public void removeQueryRun(java.lang.String singleStringQuery)
public void replaceObjectId(javax.jdo.spi.PersistenceCapable pc,
java.lang.Object oldID,
java.lang.Object newID)
pc - The Persistence Capable objectoldID - the old idnewID - the new id
public void putObjectIntoCache(StateManager sm,
boolean level1,
boolean level2)
sm - The state managerlevel1 - Whether to put into L1 cachelevel2 - Whether to put into L2 cache
public void removeObjectFromCache(javax.jdo.spi.PersistenceCapable pc,
java.lang.Object id,
boolean level1,
boolean level2)
pc - The objectid - The id of the objectlevel1 - Whether to remove from the L1 cachelevel2 - Whether to remove from the L2 cachepublic void addConnectionEventListener(javax.resource.spi.ConnectionEventListener listener)
listener - public void removeConnectionEventListener(javax.resource.spi.ConnectionEventListener listener)
listener -
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||