Overview | Package | Class | Use | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## 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

    public abstract class AbstractLifecycleListener

extends Object
implements LifecycleListener

Abstract implementation of the `LifecycleListener` interface which delegates events to a single method.

Author:
  Steve Kim, Abe White

Constructor Summary
`AbstractLifecycleListener()`

Method Summary
`void` | `afterAttach(LifecycleEvent event)` Invoked after the instance has been attached.
`void` | `afterClear(LifecycleEvent event)` Invoked after state is cleared.
`void` | `afterDelete(LifecycleEvent event)` Invoked after the instance transferred to a deleted state.
`void` | `afterDetach(LifecycleEvent event)` Invoked after the instance has been detached.
`void` | `afterDirty(LifecycleEvent event)` Invoked after the first change is applied.
`void` | `afterDirtyFlushed(LifecycleEvent event)` Invoked after the first change is applied to a flushed instance.
`void` | `afterLoad(LifecycleEvent event)` Invoked after state has been loaded into the instance.
`void` | `afterPersist(LifecycleEvent event)` Invoked when an instance is persisted.
`void` | `afterRefresh(LifecycleEvent event)` Invoked after state has been refreshed.
`void` | `afterStore(LifecycleEvent event)` Invoked just after store.
`void` | `beforeAttach(LifecycleEvent event)` Invoked before the instance is attached.
`void` | `beforeClear(LifecycleEvent event)` Invoked before state is cleared.
`void` | `beforeDelete(LifecycleEvent event)` Invoked before the instance transferred to a deleted state.
`void` | `beforeDetach(LifecycleEvent event)` Invoked before the instance is detached.
`void` | `beforeDirty(LifecycleEvent event)` Invoked before the first change is applied.
`void` | `beforeDirtyFlushed(LifecycleEvent event)` Invoked before the first change is applied to a flushed instance.
`void` | `beforePersist(LifecycleEvent event)` Invoked before an instance is persisted.
`void` | `beforeStore(LifecycleEvent event)` Invoked just prior to store.
`protected void` | `eventOccurred(LifecycleEvent event)` Should be implemented to handle the specific lifecycle event.

Methods inherited from class java.lang.Object
`clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

Constructor Detail

### AbstractLifecycleListener

    public AbstractLifecycleListener()

Method Detail

### eventOccurred

    protected void eventOccurred(LifecycleEvent event)

  Should be implemented to handle the specific lifecycle event.

### beforePersist

    public void beforePersist(LifecycleEvent event)

  Description copied from interface: `PersistListener`
  Invoked before an instance is persisted.

  Specified by:
    `beforePersist` in interface `PersistListener`

### afterPersist

    public void afterPersist(LifecycleEvent event)

  Description copied from interface: `PersistListener`
  Invoked when an instance is persisted.

  Specified by:
    `afterPersist` in interface `PersistListener`

### beforeClear

    public void beforeClear(LifecycleEvent event)

  Description copied from interface: `ClearListener`
  Invoked before state is cleared.

  Specified by:
    `beforeClear` in interface `ClearListener`

### afterClear

    public void afterClear(LifecycleEvent event)

  Description copied from interface: `ClearListener`
  Invoked after state is cleared.

  Specified by:
    `afterClear` in interface `ClearListener`

### afterLoad

    public void afterLoad(LifecycleEvent event)

  Description copied from interface: `LoadListener`
  Invoked after state has been loaded into the instance.

  Specified by:
    `afterLoad` in interface `LoadListener`

### beforeDelete

    public void beforeDelete(LifecycleEvent event)

  Description copied from interface: `DeleteListener`
  Invoked before the instance transferred to a deleted state.

  Specified by:
    `beforeDelete` in interface `DeleteListener`

### afterDelete

    public void afterDelete(LifecycleEvent event)

  Description copied from interface: `DeleteListener`
  Invoked after the instance transferred to a deleted state.

  Specified by:
    `afterDelete` in interface `DeleteListener`

### beforeStore

    public void beforeStore(LifecycleEvent event)

  Description copied from interface: `StoreListener`
  Invoked just prior to store.

  Specified by:
    `beforeStore` in interface `StoreListener`

### afterStore

    public void afterStore(LifecycleEvent event)

  Description copied from interface: `StoreListener`
  Invoked just after store.

  Specified by:
    `afterStore` in interface `StoreListener`

### beforeDirty

    public void beforeDirty(LifecycleEvent event)

  Description copied from interface: `DirtyListener`
  Invoked before the first change is applied.

  Specified by:
    `beforeDirty` in interface `DirtyListener`

### afterDirty

    public void afterDirty(LifecycleEvent event)

  Description copied from interface: `DirtyListener`
  Invoked after the first change is applied.

  Specified by:
    `afterDirty` in interface `DirtyListener`

### beforeDirtyFlushed

    public void beforeDirtyFlushed(LifecycleEvent event)

  Description copied from interface: `DirtyListener`
  Invoked before the first change is applied to a flushed instance.

  Specified by:
    `beforeDirtyFlushed` in interface `DirtyListener`

### afterDirtyFlushed

    public void afterDirtyFlushed(LifecycleEvent event)

  Description copied from interface: `DirtyListener`
  Invoked after the first change is applied to a flushed instance.

  Specified by:
    `afterDirtyFlushed` in interface `DirtyListener`

### afterRefresh

    public void afterRefresh(LifecycleEvent event)

  Description copied from interface: `LoadListener`
  Invoked after state has been refreshed.

  Specified by:
    `afterRefresh` in interface `LoadListener`

### beforeDetach

    public void beforeDetach(LifecycleEvent event)

  Description copied from interface: `DetachListener`
  Invoked before the instance is detached.

  Specified by:
    `beforeDetach` in interface `DetachListener`

### afterDetach

    public void afterDetach(LifecycleEvent event)

  Description copied from interface: `DetachListener`
  Invoked after the instance has been detached.

  Specified by:
    `afterDetach` in interface `DetachListener`

### beforeAttach

    public void beforeAttach(LifecycleEvent event)

  Description copied from interface: `AttachListener`
  Invoked before the instance is attached.

  Specified by:
    `beforeAttach` in interface `AttachListener`

### afterAttach

    public void afterAttach(LifecycleEvent event)

  Description copied from interface: `AttachListener`
  Invoked after the instance has been attached.

  Specified by:
    `afterAttach` in interface `AttachListener`

Overview | Package | Class | Use | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

Copyright © 2006-2013 Apache Software Foundation. All Rights Reserved.