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.internal
Class DefaultFlushEntityEventListener

    java.lang.Object
      org.hibernate.event.internal.DefaultFlushEntityEventListener

All Implemented Interfaces:
  Serializable, FlushEntityEventListener

Direct Known Subclasses:
  EJB3FlushEntityEventListener

    public class DefaultFlushEntityEventListener

extends Object
implements FlushEntityEventListener

An event that occurs for each entity instance at flush time

See Also:
  Serialized Form

Constructor Summary
`DefaultFlushEntityEventListener()`

Method Summary
`void` | `checkId(Object object, EntityPersister persister, Serializable id, SessionImplementor session)` make sure user didn't mangle the id
`protected void` | `dirtyCheck(FlushEntityEvent event)` Perform a dirty check, and attach the results to the event
`protected boolean` | `handleInterception(FlushEntityEvent event)`
`protected boolean` | `invokeInterceptor(SessionImplementor session, Object entity, EntityEntry entry, Object[] values, EntityPersister persister)`
`protected boolean` | `isUpdateNecessary(FlushEntityEvent event)` Performs all necessary checking to determine if an entity needs an SQL update to synchronize its state to the database.
`void` | `onFlushEntity(FlushEntityEvent event)` Flushes a single entity's state to the database, by scheduling an update action, if necessary

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

Constructor Detail

### DefaultFlushEntityEventListener

    public DefaultFlushEntityEventListener()

Method Detail

### checkId

    public void checkId(Object object,
                        EntityPersister persister,
                        Serializable id,
                        SessionImplementor session)
                 throws HibernateException

  make sure user didn't mangle the id

  Throws:
    `HibernateException`

### onFlushEntity

    public void onFlushEntity(FlushEntityEvent event)
                       throws HibernateException

  Flushes a single entity's state to the database, by scheduling an update action, if necessary

  Specified by:
    `onFlushEntity` in interface `FlushEntityEventListener`
  Throws:
    `HibernateException`

### handleInterception

    protected boolean handleInterception(FlushEntityEvent event)

### invokeInterceptor

    protected boolean invokeInterceptor(SessionImplementor session,
                                        Object entity,
                                        EntityEntry entry,
                                        Object[] values,
                                        EntityPersister persister)

### isUpdateNecessary

    protected final boolean isUpdateNecessary(FlushEntityEvent event)
                                       throws HibernateException

  Performs all necessary checking to determine if an entity needs an SQL update to synchronize its state to the database. Modifies the event by side-effect! Note: this method is quite slow, avoid calling if possible!

  Throws:
    `HibernateException`

### dirtyCheck

    protected void dirtyCheck(FlushEntityEvent event)
                       throws HibernateException

  Perform a dirty check, and attach the results to the event

  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

Copyright © 2001-2012 Red Hat, Inc. All Rights Reserved.