Class CollectionEntry

  • All Implemented Interfaces:
    Serializable

    public final class CollectionEntry
    extends Object
    implements Serializable
    We need an entry to tell us all about the current state of a collection with respect to its persistent state
    See Also:
    Serialized Form
    • Method Detail

      • afterAction

        public void afterAction​(PersistentCollection<?> collection)
        Called after execution of an action
      • getKey

        public @Nullable Object getKey()
      • getRole

        public @Nullable String getRole()
      • resetStoredSnapshot

        public void resetStoredSnapshot​(PersistentCollection<?> collection,
                                        Serializable storedSnapshot)
        Reset the stored snapshot for both the persistent collection and this collection entry. Used during the merge of detached collections.
        Parameters:
        collection - the persistentcollection to be updated
        storedSnapshot - the new stored snapshot
      • 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()
      • setCurrentPersister

        public void setCurrentPersister​(@Nullable CollectionPersister currentPersister)
      • getCurrentKey

        public @Nullable Object getCurrentKey()
        This is only available late during the flush cycle
      • setCurrentKey

        public void setCurrentKey​(@Nullable Object currentKey)
      • getLoadedPersister

        public @Nullable CollectionPersister getLoadedPersister()
        This is only available late during the flush cycle
      • getLoadedKey

        public @Nullable Object getLoadedKey()
      • setRole

        public void setRole​(@Nullable String role)
      • serialize

        public void serialize​(ObjectOutputStream oos)
                       throws IOException
        Custom serialization routine used during serialization of a Session/PersistenceContext for increased performance.
        Parameters:
        oos - The stream to which we should write the serial data.
        Throws:
        IOException