Class EntityAction

    • Constructor Detail

      • EntityAction

        protected EntityAction​(EventSource session,
                               Object id,
                               Object instance,
                               EntityPersister persister)
        Instantiate an action.
        Parameters:
        session - The session from which this action is coming.
        id - The id of the entity
        instance - The entity instance
        persister - The entity persister
    • Method Detail

      • isVeto

        public boolean isVeto()
      • setVeto

        public void setVeto​(boolean veto)
      • hasPostCommitEventListeners

        protected abstract boolean hasPostCommitEventListeners()
      • needsAfterTransactionCompletion

        protected boolean needsAfterTransactionCompletion()
      • getEntityName

        public String getEntityName()
        entity name accessor
        Returns:
        The entity name
      • getId

        public final Object getId()
        entity id accessor
        Returns:
        The entity id
      • getInstance

        public final Object getInstance()
        entity instance accessor
        Returns:
        The entity instance
      • getSession

        public final EventSource getSession()
        originating session accessor
        Returns:
        The session from which this action originated.
      • getPersister

        public final EntityPersister getPersister()
        entity persister accessor
        Returns:
        The entity persister
      • getPropertySpaces

        public final String[] getPropertySpaces()
        Description copied from interface: Executable
        What spaces (tables) are affected by this action?
        Specified by:
        getPropertySpaces in interface Executable
        Returns:
        The spaces affected by this action.
      • beforeExecutions

        public void beforeExecutions()
        Description copied from interface: Executable
        Called before executing any actions. Gives actions a chance to perform any preparation.
        Specified by:
        beforeExecutions in interface Executable
      • getPrimarySortClassifier

        public String getPrimarySortClassifier()
        Description copied from interface: ComparableExecutable
        This affect sorting order of the executables, when sorting is enabled.
        Specified by:
        getPrimarySortClassifier in interface ComparableExecutable
        Returns:
        the primary sorting attribute; typically the entity name or collection role.
      • getSecondarySortIndex

        public Object getSecondarySortIndex()
        Description copied from interface: ComparableExecutable
        This affect sorting order of the executables, when sorting is enabled.
        Specified by:
        getSecondarySortIndex in interface ComparableExecutable
        Returns:
        the secondary sorting attribute, applied when getPrimarySortClassifier matches during a comparison; typically the entity key or collection key.
      • afterDeserialize

        public void afterDeserialize​(EventSource session)
        Reconnect to session after deserialization...
        Specified by:
        afterDeserialize in interface Executable
        Parameters:
        session - The session being deserialized