|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
The PersistenceManagerSvr interface identifies the set of PersistentManager
methods that are invokable only from classes running in the method server
Supported API: true
Extendable: false
Method Summary | |
BinaryLink |
copyLink(BinaryLink linkToCopy,
Persistable roleObject,
String roleObjectRole,
Persistable otherRoleObject)
Copies a link by duplicating it, replacing the role members, and persisting the new link using a server-side insert. |
WTValuedHashMap |
copyLink(WTValuedHashMap linksToCopy)
Copies links in the specified Map for each key (original copy) by persisting the associated value (new link) using a server-side insert. |
int |
execute(AbstractBatchSpec a_batchSpec)
This method executes a batch update or delete operation on the specified Batch Specification. |
QueryResult |
expand(Persistable obj,
String role,
Class linkClass,
boolean onlyOtherSide)
Retrieves objects related to the given persistable object given a role and link class. |
QueryResult |
expand(Persistable obj,
String role,
QuerySpec criteria,
boolean onlyOtherSide)
Retrieves objects related to the given persistable object given a role, an association name and selection criteria. |
void |
insert(Persistable obj)
Stores the given Persistable object into the datastore. |
void |
insert(Persistable obj,
Timestamp createDate,
Timestamp modifyDate)
Stores the given Persistable object into the datastore. |
void |
insert(WTCollection a_objects)
Stores the given Persistable object into the datastore. |
void |
lock(Object a_class)
Performs a database lock on the given class table. |
void |
lock(Persistable obj)
Performs a database lock on the given Persistable's row. |
void |
lock(Persistable obj,
boolean wait)
Performs a database lock on the given Persistable's row. |
void |
lock(Persistable obj,
int retry,
int sleepIntervalSeconds)
Performs a database lock on the given Persistable's row. |
QueryResult |
query(Class targetLinkClass,
ObjectIdentifier obj1Oid,
String obj1Role,
ObjectIdentifier obj2Oid)
Retrieves any and all link objects that exist between two Persistable objects given their object identifiers. |
QueryResult |
query(Class targetLinkClass,
Persistable obj1,
String obj1Role,
Persistable obj2)
Retrieves any and all link objects that exist between two given Persistable objects. |
QueryResult |
query(QuerySpec qs)
Retrieves persistable objects from the datastore given the specified selection criteria. |
QueryResult |
query(StatementSpec a_statementSpec)
Retrieves persistable objects from the datastore given the specified statement. |
QueryResult |
query(StatementSpec a_statementSpec,
AccessControllerProcessor a_accessControllerProcessor)
Supported API: false |
void |
query(StatementSpec a_statementSpec,
AccessControllerProcessor a_accessControllerProcessor,
ResultProcessor a_resultProcessor)
This method queries the persistent datastore. |
void |
query(StatementSpec a_statementSpec,
ResultProcessor a_resultProcessor)
Retrieves persistable objects from the datastore for the specified statement. |
void |
remove(Persistable obj)
Removes the given persistable object from the datastore. |
void |
remove(WTSet a_objects)
Removes the specified objects from the datastore. |
Persistable |
restore(ObjectIdentifier objId)
Retrieves a Persistable object from the database given its object identifier. |
Persistable |
restore(ObjectIdentifier objId,
boolean checkFreshness)
Retrieves a Persistable object from the database given its object identifier. |
Persistable |
restore(ObjectIdentifier objId,
boolean checkFreshness,
boolean lock)
Retrieves a Persistable object from the database given its object identifier. |
Persistable |
restore(Persistable obj)
Retrieves the given Persistable object from the database to restore its state. |
Persistable |
restore(Persistable obj,
boolean fullRestore)
Retrieves the given Persistable object from the database to restore its state. |
Persistable |
restore(Persistable obj,
boolean fullRestore,
boolean inPlace)
Retrieves the given Persistable object from the database to restore its state. |
Persistable |
restore(Persistable obj,
boolean fullRestore,
boolean inPlace,
boolean checkFreshness)
Retrieves the given Persistable object from the database to restore its state. |
Persistable |
restore(Persistable obj,
boolean fullRestore,
boolean inPlace,
boolean checkFreshness,
boolean lock)
Retrieves the given Persistable object from the database to restore its state. |
Persistable |
store(Persistable obj,
Timestamp createDate,
Timestamp modifyDate)
Stores the given Persistable object in the datastore with the given timestamps. |
void |
update(Persistable obj)
Updates the given Persistable object in the datastore. |
void |
update(Persistable obj,
boolean changeModifyDate)
Updates the given Persistable object in the datastore. |
void |
update(Persistable obj,
String attrName,
ObjectMappable objAttr)
Supported API: false |
void |
update(WTCollection a_objects)
Updates the specified objects in the datastore. |
void |
update(WTCollection a_objects,
boolean changeModifyDate)
Updates the specified objects in the datastore. |
long |
updateLob(Persistable obj,
LobLocator lob,
InputStream stream,
boolean changeModifyDate)
Saves the specified input stream of unknown length as a Lob of the given Persistable object. |
void |
updateLob(Persistable obj,
LobLocator lob,
InputStream stream,
long length,
boolean changeModifyDate)
Saves the specified input stream as a Lob of the given Persistable object. |
Method Detail |
public QueryResult expand(Persistable obj, String role, Class linkClass, boolean onlyOtherSide) throws WTException
obj
- The persistable object to navigaterole
- The role to navigate tolinkClass
- The link class to navigateonlyOtherSide
-
WTException
public QueryResult expand(Persistable obj, String role, QuerySpec criteria, boolean onlyOtherSide) throws WTException
obj
- The persistable object to navigaterole
- The role to navigate tocriteria
- Selection criteria for the navigate. This QuerySpec must contain the target and link class at class index 0 and 1, respectively.onlyOtherSide
-
WTException
public void insert(Persistable obj) throws WTException
obj
- The object to be inserted into the datastore
WTException
public QueryResult query(QuerySpec qs) throws WTException
qs
-
WTException
public QueryResult query(Class targetLinkClass, Persistable obj1, String obj1Role, Persistable obj2) throws WTException
targetLinkClass
- obj1
- obj1Role
- obj2
-
WTException
public QueryResult query(Class targetLinkClass, ObjectIdentifier obj1Oid, String obj1Role, ObjectIdentifier obj2Oid) throws WTException, InvalidRoleException
targetLinkClass
- obj1Oid
- obj1Role
- obj2Oid
-
WTException
InvalidRoleException
public void remove(Persistable obj) throws WTException
obj
-
WTException
public Persistable restore(Persistable obj, boolean fullRestore) throws WTException, ObjectNoLongerExistsException
obj
- fullRestore
- Set to true if the object references for the target object should be refreshed as well.
WTException
ObjectNoLongerExistsException
public Persistable restore(Persistable obj) throws WTException, ObjectNoLongerExistsException
obj
-
WTException
ObjectNoLongerExistsException
public Persistable restore(ObjectIdentifier objId) throws WTException, ObjectNoLongerExistsException
objId
- The object identifier of the persistable object to be restored
WTException
ObjectNoLongerExistsException
public Persistable restore(ObjectIdentifier objId, boolean checkFreshness) throws WTException, ObjectNoLongerExistsException
objId
- The object identifier of the persistable object to be restoredcheckFreshness
- Set to true if the target object should be checked for freshness to determine whether it is an expired or stale proxy.
WTException
ObjectNoLongerExistsException
public void update(Persistable obj) throws WTException
obj
-
WTException
public void update(Persistable obj, boolean changeModifyDate) throws WTException
obj
- The object to be modifiedchangeModifyDate
- Set to true if the modifyTimestamp is to be updated.
WTException
public void update(Persistable obj, String attrName, ObjectMappable objAttr) throws WTException
obj
- attrName
- objAttr
-
WTException
public void updateLob(Persistable obj, LobLocator lob, InputStream stream, long length, boolean changeModifyDate) throws WTException
obj
- lob
- stream
- length
- changeModifyDate
-
WTException
public long updateLob(Persistable obj, LobLocator lob, InputStream stream, boolean changeModifyDate) throws WTException
obj
- lob
- stream
- changeModifyDate
-
WTException
public void lock(Persistable obj) throws WTException
obj
-
WTException
public void lock(Persistable obj, boolean wait) throws WTException
obj
- wait
-
WTException
public void lock(Persistable obj, int retry, int sleepIntervalSeconds) throws WTException
obj
- retry
- sleepIntervalSeconds
-
WTException
public BinaryLink copyLink(BinaryLink linkToCopy, Persistable roleObject, String roleObjectRole, Persistable otherRoleObject) throws WTException, InvalidRoleException
linkToCopy
- The original link to copy.roleObject
- The object on the "roleObjectRole" side to assign. If left null, the "linkToCopy"'s role object is not replaced.roleObjectRole
- The role the "roleObject" plays in the association.otherRoleObject
- The object on the other side of the "roleObjectRole" side to assign. If left null, the "linkToCopy"'s other side role object is not replaced.
WTException
InvalidRoleException
public QueryResult query(StatementSpec a_statementSpec) throws WTException
a_statementSpec
- The statement instance specifying the query to execute.
WTException
public Persistable restore(Persistable obj, boolean fullRestore, boolean inPlace) throws WTException, ObjectNoLongerExistsException
obj
- fullRestore
- Set to true if the object references for the target object should be refreshed as well.inPlace
- Set to true if the target object should be refreshed in place.
WTException
ObjectNoLongerExistsException
public Persistable restore(Persistable obj, boolean fullRestore, boolean inPlace, boolean checkFreshness) throws WTException, ObjectNoLongerExistsException
obj
- fullRestore
- Set to true if the object references for the target object should be refreshed as well.inPlace
- Set to true if the target object should be refreshed in place.checkFreshness
- Set to true if the target object should be checked for freshness to determine whether it is an expired or stale proxy.
WTException
ObjectNoLongerExistsException
public void insert(Persistable obj, Timestamp createDate, Timestamp modifyDate) throws WTException
obj
- The object to be inserted into the datastorecreateDate
- modifyDate
-
WTException
public Persistable store(Persistable obj, Timestamp createDate, Timestamp modifyDate) throws WTException
obj
- createDate
- modifyDate
-
WTException
public void query(StatementSpec a_statementSpec, ResultProcessor a_resultProcessor) throws WTException
a_statementSpec
- a_resultProcessor
-
WTException
public QueryResult query(StatementSpec a_statementSpec, AccessControllerProcessor a_accessControllerProcessor) throws WTException
a_statementSpec
- a_accessControllerProcessor
-
WTException
public void lock(Object a_class) throws WTException
a_class
- The String representation of class name or Class
WTException
public Persistable restore(Persistable obj, boolean fullRestore, boolean inPlace, boolean checkFreshness, boolean lock) throws WTException, ObjectNoLongerExistsException
obj
- fullRestore
- Set to true if the object references for the target object should be refreshed as well.inPlace
- Set to true if the target object should be refreshed in place.checkFreshness
- Set to true if the target object should be checked for freshness to determine whether it is an expired or stale proxy.lock
- Specifies whether the object should be locked as part of the restore.
WTException
ObjectNoLongerExistsException
public int execute(AbstractBatchSpec a_batchSpec) throws WTException
a_batchSpec
- Batch Specification to execute.
WTException
public void insert(WTCollection a_objects) throws WTException
a_objects
- The objects to be inserted into the datastore. The collection should contain full Persistable objects.
WTException
public void update(WTCollection a_objects) throws WTException
a_objects
- Objects to update in the datastore.
WTException
public void remove(WTSet a_objects) throws WTException
a_objects
- Objects to remove from the datastore.
WTException
public WTValuedHashMap copyLink(WTValuedHashMap linksToCopy) throws WTException
linksToCopy
- Map of original link objects (keys) and associated new link objects (values).
WTException
PersistenceServerHelper.newCopyLink(BinaryLink,Persistable,String,Persistable)
,
PersistenceServerHelper.buildCopyLinkMap(WTList,WTList,List,WTList)
public void update(WTCollection a_objects, boolean changeModifyDate) throws WTException
a_objects
- Objects to update in the datastore.changeModifyDate
- Set to true if the modifyTimestamp is to be updated.
WTException
public Persistable restore(ObjectIdentifier objId, boolean checkFreshness, boolean lock) throws WTException, ObjectNoLongerExistsException
objId
- The object identifier of the persistable object to be restoredcheckFreshness
- Set to true if the target object should be checked for freshness to determine whether it is an expired or stale proxy.lock
-
WTException
ObjectNoLongerExistsException
public void query(StatementSpec a_statementSpec, AccessControllerProcessor a_accessControllerProcessor, ResultProcessor a_resultProcessor) throws WTException
a_statementSpec
- Statement to use for the query.a_accessControllerProcessor
- Access Control to apply to the results.a_resultProcessor
- Processes the results of the query.
WTException
|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |