Package org.apache.openjpa.event
Class AbstractLifecycleListener
java.lang.Object
org.apache.openjpa.event.AbstractLifecycleListener
- All Implemented Interfaces:
AttachListener,ClearListener,DeleteListener,DetachListener,DirtyListener,LifecycleListener,LoadListener,PersistListener,StoreListener
Abstract implementation of the
LifecycleListener interface
which delegates events to a single method.- Author:
- Steve Kim, Abe White
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidafterAttach(LifecycleEvent event) Invoked after the instance has been attached.voidafterClear(LifecycleEvent event) Invoked after state is cleared.voidafterDelete(LifecycleEvent event) Invoked after the instance transferred to a deleted state.voidafterDetach(LifecycleEvent event) Invoked after the instance has been detached.voidafterDirty(LifecycleEvent event) Invoked after the first change is applied.voidafterDirtyFlushed(LifecycleEvent event) Invoked after the first change is applied to a flushed instance.voidafterLoad(LifecycleEvent event) Invoked after state has been loaded into the instance.voidafterPersist(LifecycleEvent event) Invoked when an instance is persisted.voidafterRefresh(LifecycleEvent event) Invoked after state has been refreshed.voidafterStore(LifecycleEvent event) Invoked just after store.voidbeforeAttach(LifecycleEvent event) Invoked before the instance is attached.voidbeforeClear(LifecycleEvent event) Invoked before state is cleared.voidbeforeDelete(LifecycleEvent event) Invoked before the instance transferred to a deleted state.voidbeforeDetach(LifecycleEvent event) Invoked before the instance is detached.voidbeforeDirty(LifecycleEvent event) Invoked before the first change is applied.voidbeforeDirtyFlushed(LifecycleEvent event) Invoked before the first change is applied to a flushed instance.voidbeforePersist(LifecycleEvent event) Invoked before an instance is persisted.voidbeforeStore(LifecycleEvent event) Invoked just prior to store.protected voideventOccurred(LifecycleEvent event) Should be implemented to handle the specific lifecycle event.
-
Constructor Details
-
AbstractLifecycleListener
public AbstractLifecycleListener()
-
-
Method Details
-
eventOccurred
Should be implemented to handle the specific lifecycle event. -
beforePersist
Description copied from interface:PersistListenerInvoked before an instance is persisted.- Specified by:
beforePersistin interfacePersistListener
-
afterPersist
Description copied from interface:PersistListenerInvoked when an instance is persisted.- Specified by:
afterPersistin interfacePersistListener
-
beforeClear
Description copied from interface:ClearListenerInvoked before state is cleared.- Specified by:
beforeClearin interfaceClearListener
-
afterClear
Description copied from interface:ClearListenerInvoked after state is cleared.- Specified by:
afterClearin interfaceClearListener
-
afterLoad
Description copied from interface:LoadListenerInvoked after state has been loaded into the instance.- Specified by:
afterLoadin interfaceLoadListener
-
beforeDelete
Description copied from interface:DeleteListenerInvoked before the instance transferred to a deleted state.- Specified by:
beforeDeletein interfaceDeleteListener
-
afterDelete
Description copied from interface:DeleteListenerInvoked after the instance transferred to a deleted state.- Specified by:
afterDeletein interfaceDeleteListener
-
beforeStore
Description copied from interface:StoreListenerInvoked just prior to store.- Specified by:
beforeStorein interfaceStoreListener
-
afterStore
Description copied from interface:StoreListenerInvoked just after store.- Specified by:
afterStorein interfaceStoreListener
-
beforeDirty
Description copied from interface:DirtyListenerInvoked before the first change is applied.- Specified by:
beforeDirtyin interfaceDirtyListener
-
afterDirty
Description copied from interface:DirtyListenerInvoked after the first change is applied.- Specified by:
afterDirtyin interfaceDirtyListener
-
beforeDirtyFlushed
Description copied from interface:DirtyListenerInvoked before the first change is applied to a flushed instance.- Specified by:
beforeDirtyFlushedin interfaceDirtyListener
-
afterDirtyFlushed
Description copied from interface:DirtyListenerInvoked after the first change is applied to a flushed instance.- Specified by:
afterDirtyFlushedin interfaceDirtyListener
-
afterRefresh
Description copied from interface:LoadListenerInvoked after state has been refreshed.- Specified by:
afterRefreshin interfaceLoadListener
-
beforeDetach
Description copied from interface:DetachListenerInvoked before the instance is detached.- Specified by:
beforeDetachin interfaceDetachListener
-
afterDetach
Description copied from interface:DetachListenerInvoked after the instance has been detached.- Specified by:
afterDetachin interfaceDetachListener
-
beforeAttach
Description copied from interface:AttachListenerInvoked before the instance is attached.- Specified by:
beforeAttachin interfaceAttachListener
-
afterAttach
Description copied from interface:AttachListenerInvoked after the instance has been attached.- Specified by:
afterAttachin interfaceAttachListener
-