public class

DefaultFlushEntityEventListener

extends Object
implements FlushEntityEventListener
java.lang.Object
   ↳ org.hibernate.event.def.DefaultFlushEntityEventListener

Class Overview

An event that occurs for each entity instance at flush time

Summary

Public Constructors
DefaultFlushEntityEventListener()
Public Methods
void checkId(Object object, EntityPersister persister, Serializable id, EntityMode entityMode, SessionImplementor session)
make sure user didn't mangle the id
void onFlushEntity(FlushEntityEvent event)
Flushes a single entity's state to the database, by scheduling an update action, if necessary
Protected Methods
void dirtyCheck(FlushEntityEvent event)
Perform a dirty check, and attach the results to the event
boolean handleInterception(FlushEntityEvent event)
boolean invokeInterceptor(SessionImplementor session, Object entity, EntityEntry entry, Object[] values, EntityPersister persister)
final 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 validate(Object entity, EntityPersister persister, Status status, EntityMode entityMode)
[Expand]
Inherited Methods
From class java.lang.Object
From interface org.hibernate.event.FlushEntityEventListener

Public Constructors

public DefaultFlushEntityEventListener ()

Public Methods

public void checkId (Object object, EntityPersister persister, Serializable id, EntityMode entityMode, SessionImplementor session)

make sure user didn't mangle the id

public void onFlushEntity (FlushEntityEvent event)

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

Protected Methods

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 final boolean isUpdateNecessary (FlushEntityEvent event)

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!

protected void validate (Object entity, EntityPersister persister, Status status, EntityMode entityMode)