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.hibernate.event.def
Class AbstractFlushingEventListener

    java.lang.Object
      org.hibernate.event.def.AbstractFlushingEventListener

All Implemented Interfaces:
  Serializable

Direct Known Subclasses:
  DefaultAutoFlushEventListener, DefaultDirtyCheckEventListener, DefaultFlushEventListener

    public abstract class AbstractFlushingEventListener

extends Object
implements Serializable

A convenience base class for listeners whose functionality results in flushing.

Author:
  Steve Eberole
See Also:
  Serialized Form

Constructor Summary
`AbstractFlushingEventListener()`

Method Summary
`protected void` | `flushEverythingToExecutions(FlushEvent event)` Coordinates the processing necessary to get things ready for executions as db calls by preping the session caches and moving the appropriate entities and collections to their respective execution queues.
`protected Object` | `getAnything()`
`protected CascadingAction` | `getCascadingAction()`
`protected void` | `performExecutions(EventSource session)` Execute all SQL and second-level cache updates, in a special order so that foreign-key constraints cannot be violated: Inserts, in the order they were performed Updates Deletion of collection elements Insertion of collection elements Deletes, in the order they were performed
`protected void` | `postFlush(SessionImplementor session)` 1.

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

Constructor Detail

### AbstractFlushingEventListener

    public AbstractFlushingEventListener()

Method Detail

### flushEverythingToExecutions

    protected void flushEverythingToExecutions(FlushEvent event)
                                        throws HibernateException

  Coordinates the processing necessary to get things ready for executions as db calls by preping the session caches and moving the appropriate entities and collections to their respective execution queues.

  Parameters:
    `event` - The flush event.
  Throws:
    `HibernateException` - Error flushing caches to execution queues.

### getAnything

    protected Object getAnything()

### getCascadingAction

    protected CascadingAction getCascadingAction()

### performExecutions

    protected void performExecutions(EventSource session)
                              throws HibernateException

  Execute all SQL and second-level cache updates, in a special order so that foreign-key constraints cannot be violated:
  1. Inserts, in the order they were performed
  2. Updates
  3. Deletion of collection elements
  4. Insertion of collection elements
  5. Deletes, in the order they were performed

  Throws:
    `HibernateException`

### postFlush

    protected void postFlush(SessionImplementor session)
                      throws HibernateException

  1. Recreate the collection key -> collection map 2. rebuild the collection entries 3. call Interceptor.postFlush()

  Throws:
    `HibernateException`

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