Class ReservationCountEntityListener
java.lang.Object
ch.tocco.nice2.persist.core.api.util.CollectingAfterFlushEntityListener<ReservationCountEntityListener.EventContext>
ch.tocco.nice2.optional.reservation.impl.entitylistener.ReservationCountEntityListener
- All Implemented Interfaces:
EntityFacadeListener,CommitListener,EventListener
public class ReservationCountEntityListener
extends CollectingAfterFlushEntityListener<ReservationCountEntityListener.EventContext>
count duration_hour_actual fields and write it to related event
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic classstatic classNested classes/interfaces inherited from class ch.tocco.nice2.persist.core.api.util.CollectingAfterFlushEntityListener
CollectingAfterFlushEntityListener.EntityContext -
Constructor Summary
ConstructorsConstructorDescriptionReservationCountEntityListener(SecurityManager securityManager, PersistenceService persistenceService, QueryBuilderFactory queryBuilderFactory, DataModel dataModel) -
Method Summary
Modifier and TypeMethodDescriptionbooleanprotected voidprotected voidprotected voidintpriority()Defines execution order of allCollectingAfterFlushEntityListener.Methods inherited from class ch.tocco.nice2.persist.core.api.util.CollectingAfterFlushEntityListener
afterCommit, afterFlush, beforeCommit, entityChanging, entityCreating, entityDeleting, entityRelationChanging, getEntityContext, onEntityCreatingMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface ch.tocco.nice2.persist.core.api.entity.events.EntityFacadeListener
entityReceivedValues, handleSessionOnlyEntity
-
Constructor Details
-
ReservationCountEntityListener
public ReservationCountEntityListener(SecurityManager securityManager, PersistenceService persistenceService, QueryBuilderFactory queryBuilderFactory, DataModel dataModel)
-
-
Method Details
-
onEntityDeleting
-
onEntityChanging
-
onEntityRelationChanging
-
onAfterFlush
- Specified by:
onAfterFlushin classCollectingAfterFlushEntityListener<ReservationCountEntityListener.EventContext>- Returns:
- true if this listeners has made any changes to the database
-
priority
public int priority()Description copied from class:CollectingAfterFlushEntityListenerDefines execution order of allCollectingAfterFlushEntityListener. It is important to make sure that other listeners are not affected.- Specified by:
priorityin interfaceCommitListener- Specified by:
priorityin classCollectingAfterFlushEntityListener<ReservationCountEntityListener.EventContext>
-
createEntityContext
-