org.proteios.core
Class ExtendedPropertyAccessor
java.lang.Object
org.proteios.core.ExtendedPropertyAccessor
- All Implemented Interfaces:
- org.hibernate.property.PropertyAccessor
public final class ExtendedPropertyAccessor
- extends Object
- implements org.hibernate.property.PropertyAccessor
This class is used to interface with Hibernate for extended properties. We
need specialized getter and setter methods since there are no regulare get
and set methods for the extended properties. Ie. we have to call
getExtended("name") instead of getName().
During startup Hibernate creates a pair of Getter and
Setter objects for each extended property of an
Extendable item. These objects are then used to access the
extended properties for all items via the GetterSetter.get and
GetterSetter.set methods.
- Version:
- 2.0
- Author:
- Nicklas, Samuel
- See Also:
ExtendableData,
ExtendedProperty,
ExtendedProperties
|
Method Summary |
org.hibernate.property.Getter |
getGetter(Class clazz,
String property)
Create a Getter object for the specified class and
property. |
org.hibernate.property.Setter |
getSetter(Class clazz,
String property)
Create a Setter object for the specified class and
property. |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
ExtendedPropertyAccessor
public ExtendedPropertyAccessor()
getGetter
public org.hibernate.property.Getter getGetter(Class clazz,
String property)
throws org.hibernate.PropertyNotFoundException
- Create a
Getter object for the specified class and
property.
- Specified by:
getGetter in interface org.hibernate.property.PropertyAccessor
- Parameters:
clazz - The Class of the itemproperty - The name of the property
- Throws:
org.hibernate.PropertyNotFoundException - If the item is not
Extendable
getSetter
public org.hibernate.property.Setter getSetter(Class clazz,
String property)
throws org.hibernate.PropertyNotFoundException
- Create a
Setter object for the specified class and
property.
- Specified by:
getSetter in interface org.hibernate.property.PropertyAccessor
- Parameters:
clazz - The Class of the itemproperty - The name of the property
- Throws:
org.hibernate.PropertyNotFoundException - If the item is not
Extendable