类 AbstractInterceptor
- java.lang.Object
-
- org.hibernate.bytecode.enhance.spi.interceptor.AbstractInterceptor
-
- 所有已实现的接口:
SessionAssociableInterceptor,LazyPropertyInitializer.InterceptorImplementor,PersistentAttributeInterceptor
- 直接已知子类:
AbstractLazyLoadInterceptor
public abstract class AbstractInterceptor extends Object implements SessionAssociableInterceptor
- 作者:
- Steve Ebersole
-
-
构造器概要
构造器 构造器 说明 AbstractInterceptor(String entityName)
-
方法概要
所有方法 实例方法 抽象方法 具体方法 修饰符和类型 方法 说明 booleanallowLoadOutsideTransaction()StringgetEntityName()SharedSessionContractImplementorgetLinkedSession()StringgetSessionFactoryUuid()protected abstract ObjecthandleRead(Object target, String attributeName, Object value)Handle the case of reading an attribute.protected abstract ObjecthandleWrite(Object target, String attributeName, Object oldValue, Object newValue)Handle the case of writing an attribute.booleanreadBoolean(Object obj, String name, boolean oldValue)bytereadByte(Object obj, String name, byte oldValue)charreadChar(Object obj, String name, char oldValue)doublereadDouble(Object obj, String name, double oldValue)floatreadFloat(Object obj, String name, float oldValue)intreadInt(Object obj, String name, int oldValue)longreadLong(Object obj, String name, long oldValue)ObjectreadObject(Object obj, String name, Object oldValue)shortreadShort(Object obj, String name, short oldValue)voidsetSession(SharedSessionContractImplementor session)voidunsetSession()booleanwriteBoolean(Object obj, String name, boolean oldValue, boolean newValue)bytewriteByte(Object obj, String name, byte oldValue, byte newValue)charwriteChar(Object obj, String name, char oldValue, char newValue)doublewriteDouble(Object obj, String name, double oldValue, double newValue)floatwriteFloat(Object obj, String name, float oldValue, float newValue)intwriteInt(Object obj, String name, int oldValue, int newValue)longwriteLong(Object obj, String name, long oldValue, long newValue)ObjectwriteObject(Object obj, String name, Object oldValue, Object newValue)shortwriteShort(Object obj, String name, short oldValue, short newValue)-
从类继承的方法 java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
从接口继承的方法 org.hibernate.engine.spi.PersistentAttributeInterceptor
attributeInitialized, getInitializedLazyAttributeNames
-
-
-
-
构造器详细资料
-
AbstractInterceptor
public AbstractInterceptor(String entityName)
-
-
方法详细资料
-
getEntityName
public String getEntityName()
-
getLinkedSession
public SharedSessionContractImplementor getLinkedSession()
- 指定者:
getLinkedSession在接口中SessionAssociableInterceptor
-
setSession
public void setSession(SharedSessionContractImplementor session)
- 指定者:
setSession在接口中SessionAssociableInterceptor
-
unsetSession
public void unsetSession()
- 指定者:
unsetSession在接口中SessionAssociableInterceptor
-
allowLoadOutsideTransaction
public boolean allowLoadOutsideTransaction()
-
getSessionFactoryUuid
public String getSessionFactoryUuid()
-
handleRead
protected abstract Object handleRead(Object target, String attributeName, Object value)
Handle the case of reading an attribute. The result is what is returned to the caller
-
handleWrite
protected abstract Object handleWrite(Object target, String attributeName, Object oldValue, Object newValue)
Handle the case of writing an attribute. The result is what is set as the entity state
-
readBoolean
public boolean readBoolean(Object obj, String name, boolean oldValue)
- 指定者:
readBoolean在接口中PersistentAttributeInterceptor
-
writeBoolean
public boolean writeBoolean(Object obj, String name, boolean oldValue, boolean newValue)
- 指定者:
writeBoolean在接口中PersistentAttributeInterceptor
-
readByte
public byte readByte(Object obj, String name, byte oldValue)
- 指定者:
readByte在接口中PersistentAttributeInterceptor
-
writeByte
public byte writeByte(Object obj, String name, byte oldValue, byte newValue)
- 指定者:
writeByte在接口中PersistentAttributeInterceptor
-
readChar
public char readChar(Object obj, String name, char oldValue)
- 指定者:
readChar在接口中PersistentAttributeInterceptor
-
writeChar
public char writeChar(Object obj, String name, char oldValue, char newValue)
- 指定者:
writeChar在接口中PersistentAttributeInterceptor
-
readShort
public short readShort(Object obj, String name, short oldValue)
- 指定者:
readShort在接口中PersistentAttributeInterceptor
-
writeShort
public short writeShort(Object obj, String name, short oldValue, short newValue)
- 指定者:
writeShort在接口中PersistentAttributeInterceptor
-
readInt
public int readInt(Object obj, String name, int oldValue)
- 指定者:
readInt在接口中PersistentAttributeInterceptor
-
writeInt
public int writeInt(Object obj, String name, int oldValue, int newValue)
- 指定者:
writeInt在接口中PersistentAttributeInterceptor
-
readFloat
public float readFloat(Object obj, String name, float oldValue)
- 指定者:
readFloat在接口中PersistentAttributeInterceptor
-
writeFloat
public float writeFloat(Object obj, String name, float oldValue, float newValue)
- 指定者:
writeFloat在接口中PersistentAttributeInterceptor
-
readDouble
public double readDouble(Object obj, String name, double oldValue)
- 指定者:
readDouble在接口中PersistentAttributeInterceptor
-
writeDouble
public double writeDouble(Object obj, String name, double oldValue, double newValue)
- 指定者:
writeDouble在接口中PersistentAttributeInterceptor
-
readLong
public long readLong(Object obj, String name, long oldValue)
- 指定者:
readLong在接口中PersistentAttributeInterceptor
-
writeLong
public long writeLong(Object obj, String name, long oldValue, long newValue)
- 指定者:
writeLong在接口中PersistentAttributeInterceptor
-
readObject
public Object readObject(Object obj, String name, Object oldValue)
- 指定者:
readObject在接口中PersistentAttributeInterceptor
-
writeObject
public Object writeObject(Object obj, String name, Object oldValue, Object newValue)
- 指定者:
writeObject在接口中PersistentAttributeInterceptor
-
-