|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object org.hibernate.tuple.component.AbstractComponentTuplizer
Support for tuplizers relating to components.
Field Summary | |
protected Getter[] |
getters
|
protected boolean |
hasCustomAccessors
|
protected Instantiator |
instantiator
|
protected int |
propertySpan
|
protected Setter[] |
setters
|
Constructor Summary | |
protected |
AbstractComponentTuplizer(Component component)
|
Method Summary | |
protected abstract Getter |
buildGetter(Component component,
Property prop)
|
protected abstract Instantiator |
buildInstantiator(Component component)
|
protected abstract Setter |
buildSetter(Component component,
Property prop)
|
Object |
getParent(Object component)
Retreive the current value of the parent property. |
Object |
getPropertyValue(Object component,
int i)
Extract the value of a particular property from the given entity. |
Object[] |
getPropertyValues(Object component)
Extract the current values contained on the given entity. |
boolean |
hasParentProperty()
Does the component managed by this tuuplizer contain a parent property? |
Object |
instantiate()
This method does not populate the component parent |
boolean |
isInstance(Object object)
Is the given object considered an instance of the the entity (acconting for entity-mode) managed by this tuplizer. |
boolean |
isMethodOf(Method method)
Is the given method available via the managed component as a property getter? |
void |
setParent(Object component,
Object parent,
SessionFactoryImplementor factory)
Set the value of the parent property. |
void |
setPropertyValues(Object component,
Object[] values)
Inject the given values into the given entity. |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Methods inherited from interface org.hibernate.tuple.Tuplizer |
getMappedClass |
Field Detail |
protected final Getter[] getters
protected final Setter[] setters
protected final int propertySpan
protected final Instantiator instantiator
protected final boolean hasCustomAccessors
Constructor Detail |
protected AbstractComponentTuplizer(Component component)
Method Detail |
protected abstract Instantiator buildInstantiator(Component component)
protected abstract Getter buildGetter(Component component, Property prop)
protected abstract Setter buildSetter(Component component, Property prop)
public Object getPropertyValue(Object component, int i) throws HibernateException
Tuplizer
getPropertyValue
in interface Tuplizer
component
- The entity from which to extract the property value.i
- The index of the property for which to extract the value.
HibernateException
public Object[] getPropertyValues(Object component) throws HibernateException
Tuplizer
getPropertyValues
in interface Tuplizer
component
- The entity from which to extract values.
HibernateException
public boolean isInstance(Object object)
Tuplizer
isInstance
in interface Tuplizer
object
- The object to be checked.
public void setPropertyValues(Object component, Object[] values) throws HibernateException
Tuplizer
setPropertyValues
in interface Tuplizer
component
- The entity.values
- The values to be injected.
HibernateException
public Object instantiate() throws HibernateException
instantiate
in interface Tuplizer
HibernateException
public Object getParent(Object component)
ComponentTuplizer
getParent
in interface ComponentTuplizer
component
- The component instance from which to extract the parent
property value.
public boolean hasParentProperty()
ComponentTuplizer
hasParentProperty
in interface ComponentTuplizer
public boolean isMethodOf(Method method)
ComponentTuplizer
isMethodOf
in interface ComponentTuplizer
method
- The method which to check against the managed component.
public void setParent(Object component, Object parent, SessionFactoryImplementor factory)
ComponentTuplizer
setParent
in interface ComponentTuplizer
component
- The component instance on which to set the parent.parent
- The parent to be set on the comonent.factory
- The current session factory.
|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |