Modifiers | Name | Description |
---|---|---|
protected ProxyFactory |
proxyFactory |
|
protected org.springframework.context.ApplicationEventPublisher |
publisher |
|
protected EntityReflector |
reflector |
|
protected Session |
session |
Constructor and description |
---|
EntityPersister
(MappingContext mappingContext, PersistentEntity entity, Session session, org.springframework.context.ApplicationEventPublisher publisher) |
Type Params | Return Type | Name and description |
---|---|---|
|
boolean |
cancelDelete(PersistentEntity persistentEntity, EntityAccess entityAccess) Fire the beforeDelete event on an entityAccess object and return true if the operation should be cancelled |
|
boolean |
cancelInsert(PersistentEntity persistentEntity, EntityAccess entityAccess) Fire the beforeInsert even on an entityAccess object and return true if the operation should be cancelled |
|
boolean |
cancelLoad(PersistentEntity persistentEntity, EntityAccess entityAccess) Fire the beforeDelete event on an entityAccess object and return true if the operation should be cancelled |
|
boolean |
cancelUpdate(PersistentEntity persistentEntity, EntityAccess entityAccess) Fire the beforeUpdate event on an entityAccess object and return true if the operation should be cancelled |
|
protected EntityAccess |
createEntityAccess(PersistentEntity pe, java.lang.Object obj) |
|
void |
delete(java.lang.Iterable objects) |
|
void |
delete(java.lang.Object obj) |
|
protected void |
deleteEntities(PersistentEntity pe, java.lang.Iterable objects) |
|
protected void |
deleteEntity(PersistentEntity pe, java.lang.Object obj) |
|
void |
firePostDeleteEvent(PersistentEntity persistentEntity, EntityAccess entityAccess) |
|
void |
firePostInsertEvent(PersistentEntity persistentEntity, EntityAccess entityAccess) |
|
void |
firePostLoadEvent(PersistentEntity persistentEntity, EntityAccess entityAccess) |
|
void |
firePostUpdateEvent(PersistentEntity persistentEntity, EntityAccess entityAccess) |
|
void |
firePreLoadEvent(PersistentEntity persistentEntity, EntityAccess entityAccess) |
|
java.lang.Object |
getCurrentVersion(EntityAccess ea) |
|
MappingContext |
getMappingContext() @return The MappingContext instance |
|
java.io.Serializable |
getObjectIdentifier(java.lang.Object obj) Obtains an objects identifer |
|
PersistentEntity |
getPersistentEntity() @return The PersistentEntity instance |
|
ProxyFactory |
getProxyFactory() |
|
Session |
getSession() |
|
java.lang.Class |
getType() |
|
static void |
incrementEntityVersion(EntityAccess ea) |
|
void |
incrementVersion(EntityAccess ea) |
|
java.io.Serializable |
insert(java.lang.Object obj) |
|
protected boolean |
isAssignedId(PersistentEntity persistentEntity) |
|
boolean |
isVersioned(EntityAccess ea) |
|
protected java.lang.Object |
newEntityInstance(PersistentEntity persistentEntity) |
|
java.io.Serializable |
persist(java.lang.Object obj) Persists an object returning the identifier |
|
java.util.List<java.io.Serializable> |
persist(java.lang.Iterable objs) |
|
protected java.util.List<java.io.Serializable> |
persistEntities(PersistentEntity pe, java.lang.Iterable objs) |
|
protected java.io.Serializable |
persistEntity(PersistentEntity entity, java.lang.Object obj, boolean isInsert) Subclasses should override to support explicit inserts |
|
protected java.io.Serializable |
persistEntity(PersistentEntity pe, java.lang.Object obj) Persist the given persistent entity |
|
java.lang.Object |
proxy(java.io.Serializable key) |
|
java.lang.Object |
retrieve(java.io.Serializable key) |
|
java.util.List<java.lang.Object> |
retrieveAll(java.lang.Iterable<java.io.Serializable> keys) |
|
java.util.List<java.lang.Object> |
retrieveAll(java.io.Serializable[] keys) |
|
protected java.util.List<java.lang.Object> |
retrieveAllEntities(PersistentEntity pe, java.io.Serializable[] keys) |
|
protected java.util.List<java.lang.Object> |
retrieveAllEntities(PersistentEntity pe, java.lang.Iterable<java.io.Serializable> keys) |
|
protected java.lang.Object |
retrieveEntity(PersistentEntity pe, java.io.Serializable key) Retrieve a PersistentEntity for the given mappingContext and key |
|
protected void |
setDateVersion(EntityAccess ea) |
|
void |
setObjectIdentifier(java.lang.Object obj, java.io.Serializable id) Obtains an objects identifer |
|
protected void |
setVersion(EntityAccess ea) |
Methods inherited from class | Name |
---|---|
class java.lang.Object |
java.lang.Object#wait(long, int), java.lang.Object#wait(long), java.lang.Object#wait(), java.lang.Object#equals(java.lang.Object), java.lang.Object#toString(), java.lang.Object#hashCode(), java.lang.Object#getClass(), java.lang.Object#notify(), java.lang.Object#notifyAll() |
Fire the beforeDelete event on an entityAccess object and return true if the operation should be cancelled
persistentEntity
- The entityentityAccess
- The entity accessFire the beforeInsert even on an entityAccess object and return true if the operation should be cancelled
persistentEntity
- The entityentityAccess
- The entity accessFire the beforeDelete event on an entityAccess object and return true if the operation should be cancelled
persistentEntity
- The entityentityAccess
- The entity accessFire the beforeUpdate event on an entityAccess object and return true if the operation should be cancelled
persistentEntity
- The entityentityAccess
- The entity access
Obtains an objects identifer
obj
- The object
Persists an object returning the identifier
obj
- The object to persistSubclasses should override to support explicit inserts
entity
- The entityobj
- The objectisInsert
- Whether it is an insertPersist the given persistent entity
pe
- The PersistentEntityRetrieve a PersistentEntity for the given mappingContext and key
pe
- The entitykey
- The keyObtains an objects identifer
obj
- The object