private static class NopPropertyAccessor.NopGetter
extends java.lang.Object
implements org.hibernate.property.Getter
Getter
. Always returns
null
when asked for the property value.Modifier and Type | Field and Description |
---|---|
private java.lang.Class<?> |
type
Property type
|
Constructor and Description |
---|
NopGetter(java.lang.Class<?> type)
Constructor which stores property type.
|
Modifier and Type | Method and Description |
---|---|
java.lang.Object |
get(java.lang.Object owner)
Get the property value from the given instance.
|
java.lang.Object |
getForInsert(java.lang.Object owner,
java.util.Map mergeMap,
org.hibernate.engine.spi.SessionImplementor session)
Get the property value from the given owner instance.
|
java.lang.reflect.Member |
getMember()
Retrieve the member to which this property maps.
|
java.lang.reflect.Method |
getMethod()
Optional operation (return null)
|
java.lang.String |
getMethodName()
Optional operation (return null)
|
java.lang.Class |
getReturnType()
Get the declared Java type.
|
NopGetter(java.lang.Class<?> type)
type
- DMO property type.org.hibernate.HibernateException
- if type
is not assignable from an expected
type (BaseDataType
).public java.lang.Object get(java.lang.Object owner)
get
in interface org.hibernate.property.Getter
owner
- The instance containing the value to be retrieved.null
, always.public java.lang.reflect.Member getMember()
getMember
in interface org.hibernate.property.Getter
null
, always.public java.lang.Object getForInsert(java.lang.Object owner, java.util.Map mergeMap, org.hibernate.engine.spi.SessionImplementor session) throws org.hibernate.HibernateException
getForInsert
in interface org.hibernate.property.Getter
owner
- The instance containing the value to be retrieved.mergeMap
- A map of merged persistent instances to detached instances.session
- The session from which this request originated.null
, always.org.hibernate.HibernateException
public java.lang.Class getReturnType()
getReturnType
in interface org.hibernate.property.Getter
public java.lang.String getMethodName()
getMethodName
in interface org.hibernate.property.Getter
public java.lang.reflect.Method getMethod()
getMethod
in interface org.hibernate.property.Getter