|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
public interface PersistenceEngine
The perisistence engine interface.
| Method Summary | |
|---|---|
int |
bulkUpdate(java.lang.String query)
Update/delete all objects according to the given query. |
int |
bulkUpdate(java.lang.String query,
java.lang.Object[] parameters)
Update/delete all objects according to the given query. |
void |
clear()
Clear the cache. |
void |
delete(Persistence object)
Delete the given persistent instance. |
java.util.List |
find(java.lang.Class objClass,
java.util.List propertyCriteria)
Retrieve a list of persistent instances of the specified class with the specified property criteria. |
java.util.List |
find(java.lang.Class objClass,
PropertyCriterion propertyCriterion)
Retrieve a list of persistent instances of the specified class with the specified property criterion. |
java.util.List |
find(java.lang.Class objClass,
RelationCriterion relationCriterion)
Retrieve a list of persistent instances of the specified class with the specified relation criterion. |
void |
flush()
Flush the cache. |
Persistence |
get(java.lang.Class persistenceClass,
long uidPk)
Get a persistent instance with the given id. |
PersistenceSession |
getPersistenceSession()
Returns a session. |
void |
initialize(java.lang.Object object)
Initialize the given object. |
Persistence |
load(java.lang.Class persistenceClass,
long uidPk)
Load a persistent instance with the given id. |
void |
merge(Persistence object)
Merge the given persistent instance. |
java.util.List |
retrieve(java.util.List queries)
Retrieve a list of persistent instances with the given list of queries. |
java.util.List |
retrieve(java.util.List queries,
java.lang.Object[] parameters)
Retrieve a list of persistent instances with the given list of queries. |
java.util.List |
retrieve(java.lang.String query)
Retrieve a list of persistent instances with the specified query. |
java.util.List |
retrieve(java.lang.String query,
int firstResult,
int maxRestuls)
Retrieve a list of persistent instances with the specified query and bounds, namely, the maximum number of rows to retrieve and / or the first row to retrieve. |
java.util.List |
retrieve(java.lang.String query,
java.lang.Object[] parameters)
Retrieve a list of persistent instances with the specified query. |
java.util.List |
retrieve(java.lang.String query,
java.lang.Object[] parameters,
boolean cacheQuery)
Retrieve a list of persistent instances with the specified query. |
java.util.List |
retrieve(java.lang.String queryStr,
java.lang.Object[] parameters,
int firstResult,
int maxRestuls)
Retrieve a list of persistent instances with the specified query and bounds, namely, the maximum number of rows to retrieve and / or the first row to retrieve. |
void |
save(Persistence object)
Persist the given instance. |
void |
saveOrMerge(Persistence object)
Save the persistence instance if it's new or merge the persistent instance if it exists. |
void |
saveOrUpdate(Persistence object)
Save the persistence instance if it's new or update the persistent instance if it exists. |
void |
update(Persistence object)
Update the given persistent instance. |
| Method Detail |
|---|
int bulkUpdate(java.lang.String query)
throws EpPersistenceException
query - the HQL query
EpPersistenceException - - in case of persistence errors
int bulkUpdate(java.lang.String query,
java.lang.Object[] parameters)
throws EpPersistenceException
query - the HQL queryparameters - the prameters to be used with the criteria
EpPersistenceException - - in case of persistence errorsvoid clear()
void delete(Persistence object)
throws EpPersistenceException
object - The instance to delete
EpPersistenceException - - in case of persistence errors
java.util.List find(java.lang.Class objClass,
java.util.List propertyCriteria)
throws EpPersistenceException
objClass - Class of the objectpropertyCriteria - property criteria for retrieving
EpPersistenceException - - in case of persistence errors
java.util.List find(java.lang.Class objClass,
PropertyCriterion propertyCriterion)
throws EpPersistenceException
objClass - Class of the objectpropertyCriterion - property criterion for retrieving
EpPersistenceException - - in case of persistence errors
java.util.List find(java.lang.Class objClass,
RelationCriterion relationCriterion)
throws EpPersistenceException
objClass - Class of the objectrelationCriterion - relation criterion for retrieving
EpPersistenceException - - in case of persistence errorsvoid flush()
Persistence get(java.lang.Class persistenceClass,
long uidPk)
throws EpPersistenceException
persistenceClass - the persistent class of the given id.uidPk - the persistent instance id.
EpPersistenceException - - in case of persistence errorsPersistenceSession getPersistenceSession()
void initialize(java.lang.Object object)
object - the object to initialize.
Persistence load(java.lang.Class persistenceClass,
long uidPk)
throws EpPersistenceException
persistenceClass - the persistent class of the given id.uidPk - the persistent instance id.
EpPersistenceException - - in case of persistence errors
void merge(Persistence object)
throws EpPersistenceException
object - the instance to merge
EpPersistenceException - - in case of persistence errors
java.util.List retrieve(java.util.List queries)
throws EpPersistenceException
Note: all queries must return the same type of data. Their results will be merged into the list returned by this method.
queries - the list of queries
EpPersistenceException - - in case of persistence errors
java.util.List retrieve(java.util.List queries,
java.lang.Object[] parameters)
throws EpPersistenceException
Note: all queries must return the same type of data. Their results will be merged into the list returned by this method.
queries - the list of queriesparameters - the prameters to be used with the given query
EpPersistenceException - - in case of persistence errors
java.util.List retrieve(java.lang.String query)
throws EpPersistenceException
query - the query
EpPersistenceException - - in case of persistence errors
java.util.List retrieve(java.lang.String query,
int firstResult,
int maxRestuls)
throws EpPersistenceException
query - the queryfirstResult - the first row to retrieve.maxRestuls - the maximum number of rows to retrieve.
EpPersistenceException - - in case of persistence errors
java.util.List retrieve(java.lang.String query,
java.lang.Object[] parameters)
throws EpPersistenceException
query - the queryparameters - the prameters to be used with the given query
EpPersistenceException - - in case of persistence errors
java.util.List retrieve(java.lang.String query,
java.lang.Object[] parameters,
boolean cacheQuery)
throws EpPersistenceException
query - the queryparameters - the prameters to be used with the given querycacheQuery - set it to true to cache the query result
EpPersistenceException - - in case of persistence errors
java.util.List retrieve(java.lang.String queryStr,
java.lang.Object[] parameters,
int firstResult,
int maxRestuls)
throws EpPersistenceException
queryStr - the HQL query string to be executed.firstResult - the first row to retrieve.maxRestuls - the maximum number of rows to retrieve.parameters - the prameters to be used with the criteria
EpPersistenceException - - in case of persistence errors
void save(Persistence object)
throws EpPersistenceException
object - the instance to save.
EpPersistenceException - - in case of persistence errors
void saveOrMerge(Persistence object)
throws EpPersistenceException
object - the instance to save or merge
EpPersistenceException - - in case of persistence errors
void saveOrUpdate(Persistence object)
throws EpPersistenceException
object - the instance to save or update
EpPersistenceException - - in case of persistence errors
void update(Persistence object)
throws EpPersistenceException
object - the instance to update
EpPersistenceException - - in case of persistence errors
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||