Package org.hibernate.engine
Class CollectionEntry
java.lang.Object
org.hibernate.engine.CollectionEntry
- All Implemented Interfaces:
Serializable
We need an entry to tell us all about the current state
of a collection with respect to its persistent state
- See Also:
-
Constructor Summary
ConstructorsConstructorDescriptionCollectionEntry(PersistentCollection collection, CollectionPersister loadedPersister, Serializable loadedKey, boolean ignore) For collections just loaded from the databaseCollectionEntry(CollectionPersister loadedPersister, Serializable loadedKey) For uninitialized detached collectionsCollectionEntry(CollectionPersister persister, PersistentCollection collection) For newly wrapped collections, or dereferenced collection wrappers -
Method Summary
Modifier and TypeMethodDescriptionvoidafterAction(PersistentCollection collection) Called after execution of an actionThis is only available late during the flush cyclegetKey()This is only available late during the flush cyclegetOrphans(String entityName, PersistentCollection collection) Get the collection orphans (entities which were removed from the collection)getRole()booleanbooleanbooleanbooleanisIgnore()booleanbooleanbooleanisSnapshotEmpty(PersistentCollection collection) voidpostFlush(PersistentCollection collection) Called after a successful flushvoidpostInitialize(PersistentCollection collection) voidpreFlush(PersistentCollection collection) voidsetCurrentKey(Serializable currentKey) voidsetCurrentPersister(CollectionPersister currentPersister) voidsetDorecreate(boolean dorecreate) voidsetDoremove(boolean doremove) voidsetDoupdate(boolean doupdate) voidsetProcessed(boolean processed) voidsetReached(boolean reached) voidtoString()boolean
-
Constructor Details
-
CollectionEntry
For newly wrapped collections, or dereferenced collection wrappers -
CollectionEntry
public CollectionEntry(PersistentCollection collection, CollectionPersister loadedPersister, Serializable loadedKey, boolean ignore) For collections just loaded from the database -
CollectionEntry
For uninitialized detached collections
-
-
Method Details
-
preFlush
- Throws:
HibernateException
-
postInitialize
- Throws:
HibernateException
-
postFlush
Called after a successful flush- Throws:
HibernateException
-
afterAction
Called after execution of an action -
getKey
-
getRole
-
getSnapshot
-
wasDereferenced
public boolean wasDereferenced() -
isReached
public boolean isReached() -
setReached
public void setReached(boolean reached) -
isProcessed
public boolean isProcessed() -
setProcessed
public void setProcessed(boolean processed) -
isDoupdate
public boolean isDoupdate() -
setDoupdate
public void setDoupdate(boolean doupdate) -
isDoremove
public boolean isDoremove() -
setDoremove
public void setDoremove(boolean doremove) -
isDorecreate
public boolean isDorecreate() -
setDorecreate
public void setDorecreate(boolean dorecreate) -
isIgnore
public boolean isIgnore() -
getCurrentPersister
-
setCurrentPersister
-
getCurrentKey
This is only available late during the flush cycle -
setCurrentKey
-
getLoadedPersister
This is only available late during the flush cycle -
getLoadedKey
-
setRole
-
toString
-
getOrphans
public Collection getOrphans(String entityName, PersistentCollection collection) throws HibernateException Get the collection orphans (entities which were removed from the collection)- Throws:
HibernateException
-
isSnapshotEmpty
-