站内搜索: 请输入搜索关键词
当前页面: 在线文档首页 > Hibernate 3.2.4 正式版 API 英文文档

DefaultSaveEventListener (Hibernate API Documentation) - Hibernate 3.2.4 正式版 API 英文文档


org.hibernate.event.def
Class DefaultSaveEventListener

java.lang.Object
  extended byorg.hibernate.event.def.AbstractReassociateEventListener
      extended byorg.hibernate.event.def.AbstractSaveEventListener
          extended byorg.hibernate.event.def.DefaultSaveOrUpdateEventListener
              extended byorg.hibernate.event.def.DefaultSaveEventListener
All Implemented Interfaces:
SaveOrUpdateEventListener, Serializable

public class DefaultSaveEventListener
extends DefaultSaveOrUpdateEventListener

An event handler for save() events

Author:
Gavin King
See Also:
Serialized Form

Field Summary
 
Fields inherited from class org.hibernate.event.def.AbstractSaveEventListener
DELETED, DETACHED, PERSISTENT, TRANSIENT
 
Constructor Summary
DefaultSaveEventListener()
           
 
Method Summary
protected  Serializable performSaveOrUpdate(SaveOrUpdateEvent event)
           
protected  boolean reassociateIfUninitializedProxy(Object object, SessionImplementor source)
           
protected  Serializable saveWithGeneratedOrRequestedId(SaveOrUpdateEvent event)
          Save the transient instance, assigning the right identifier
 
Methods inherited from class org.hibernate.event.def.DefaultSaveOrUpdateEventListener
entityIsDetached, entityIsPersistent, entityIsTransient, getCascadeAction, getUpdateId, invokeUpdateLifecycle, onSaveOrUpdate, performUpdate
 
Methods inherited from class org.hibernate.event.def.AbstractSaveEventListener
cascadeAfterSave, cascadeBeforeSave, getAssumedUnsaved, getEntityState, getLoggableName, getMergeMap, invokeSaveLifecycle, isVersionIncrementDisabled, performSave, performSaveOrReplicate, saveWithGeneratedId, saveWithRequestedId, substituteValuesIfNecessary, validate, visitCollectionsBeforeSave
 
Methods inherited from class org.hibernate.event.def.AbstractReassociateEventListener
reassociate
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

DefaultSaveEventListener

public DefaultSaveEventListener()
Method Detail

performSaveOrUpdate

protected Serializable performSaveOrUpdate(SaveOrUpdateEvent event)
Overrides:
performSaveOrUpdate in class DefaultSaveOrUpdateEventListener

saveWithGeneratedOrRequestedId

protected Serializable saveWithGeneratedOrRequestedId(SaveOrUpdateEvent event)
Description copied from class: DefaultSaveOrUpdateEventListener
Save the transient instance, assigning the right identifier

Overrides:
saveWithGeneratedOrRequestedId in class DefaultSaveOrUpdateEventListener
Parameters:
event - The initiating event.
Returns:
The entity's identifier value after saving.

reassociateIfUninitializedProxy

protected boolean reassociateIfUninitializedProxy(Object object,
                                                  SessionImplementor source)
Overrides:
reassociateIfUninitializedProxy in class DefaultSaveOrUpdateEventListener