Class FieldInterceptorImpl
java.lang.Object
org.hibernate.intercept.AbstractFieldInterceptor
org.hibernate.intercept.javassist.FieldInterceptorImpl
- All Implemented Interfaces:
Serializable,FieldHandler,FieldInterceptor
public final class FieldInterceptorImpl
extends AbstractFieldInterceptor
implements FieldHandler, Serializable
A field-level interceptor that initializes lazily fetched properties.
This interceptor can be attached to classes instrumented by Javassist.
Note that this implementation assumes that the instance variable
name is the same as the name of the persistent property that must
be loaded.
Note: most of the interesting functionality here is farmed off
to the super-class. The stuff here mainly acts as an adapter to the
Javassist-specific functionality, routing interception through
the super-class's intercept() method
- See Also:
-
Method Summary
Modifier and TypeMethodDescriptionbooleanreadBoolean(Object target, String name, boolean oldValue) bytechardoublereadDouble(Object target, String name, double oldValue) floatintlongreadObject(Object target, String name, Object oldValue) shorttoString()booleanwriteBoolean(Object target, String name, boolean oldValue, boolean newValue) bytechardoublewriteDouble(Object target, String name, double oldValue, double newValue) floatwriteFloat(Object target, String name, float oldValue, float newValue) intCalled to handle writing an int value to a given field.longwriteObject(Object target, String name, Object oldValue, Object newValue) shortwriteShort(Object target, String name, short oldValue, short newValue) Methods inherited from class org.hibernate.intercept.AbstractFieldInterceptor
clearDirty, dirty, getEntityName, getSession, getUninitializedFields, intercept, isDirty, isInitialized, isInitialized, isInitializing, setSession
-
Method Details
-
readBoolean
- Specified by:
readBooleanin interfaceFieldHandler
-
readByte
- Specified by:
readBytein interfaceFieldHandler
-
readChar
- Specified by:
readCharin interfaceFieldHandler
-
readDouble
- Specified by:
readDoublein interfaceFieldHandler
-
readFloat
- Specified by:
readFloatin interfaceFieldHandler
-
readInt
- Specified by:
readIntin interfaceFieldHandler
-
readLong
- Specified by:
readLongin interfaceFieldHandler
-
readShort
- Specified by:
readShortin interfaceFieldHandler
-
readObject
- Specified by:
readObjectin interfaceFieldHandler
-
writeBoolean
- Specified by:
writeBooleanin interfaceFieldHandler
-
writeByte
- Specified by:
writeBytein interfaceFieldHandler
-
writeChar
- Specified by:
writeCharin interfaceFieldHandler
-
writeDouble
- Specified by:
writeDoublein interfaceFieldHandler
-
writeFloat
- Specified by:
writeFloatin interfaceFieldHandler
-
writeInt
Description copied from interface:FieldHandlerCalled to handle writing an int value to a given field.- Specified by:
writeIntin interfaceFieldHandler- Parameters:
target- ?name- The name of the field being writtenoldValue- The old field valuenewValue- The new field value.- Returns:
- ?
-
writeLong
- Specified by:
writeLongin interfaceFieldHandler
-
writeShort
- Specified by:
writeShortin interfaceFieldHandler
-
writeObject
- Specified by:
writeObjectin interfaceFieldHandler
-
toString
-