T - The Model object typepublic abstract class AbstractPropertyModel<T> extends ChainingModel<T> implements IObjectClassAwareModel<T>, IPropertyReflectionAwareModel<T>
PropertyResolver to resolve expressions on the target model object. Note that the
property resolver by default provides access to private members and methods. If guaranteeing
encapsulation of the target objects is a big concern, you should consider using an alternative
implementation.PropertyResolver,
IDetachable,
Serialized Form| Constructor and Description |
|---|
AbstractPropertyModel(Object modelObject)
Constructor
|
| Modifier and Type | Method and Description |
|---|---|
Object |
getInnermostModelOrObject() |
T |
getObject()
Gets the model object.
|
Class<T> |
getObjectClass()
Returns the class of model object
|
String |
getPropertyExpression()
Gets the property expression for this model
|
Field |
getPropertyField()
Returns the field of model property or null if the field doesn't exist.
|
Method |
getPropertyGetter()
Returns the getter method of model property or null if the method doesn't exist.
|
Method |
getPropertySetter()
Returns the setter method of model property or null if the method doesn't exist.
|
protected abstract String |
propertyExpression() |
void |
setObject(T object)
Applies the property expression on the model object using the given object argument.
|
detach, getChainedModel, getTarget, setChainedModel, setTarget, toStringclone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, waitdetachpublic AbstractPropertyModel(Object modelObject)
modelObject - The nested model objectpublic T getObject()
IModelgetObject in interface IModel<T>getObject in class ChainingModel<T>IModel.getObject()public final String getPropertyExpression()
public void setObject(T object)
setObject in interface IModel<T>setObject in class ChainingModel<T>object - The object that will be used when setting a value on the model objectIModel.setObject(Object)public Class<T> getObjectClass()
IObjectClassAwareModelgetObjectClass in interface IObjectClassAwareModel<T>public Field getPropertyField()
IPropertyReflectionAwareModelgetPropertyField in interface IPropertyReflectionAwareModel<T>IPropertyReflectionAwareModel.getPropertyField()public Method getPropertyGetter()
IPropertyReflectionAwareModelgetPropertyGetter in interface IPropertyReflectionAwareModel<T>IPropertyReflectionAwareModel.getPropertyGetter()public Method getPropertySetter()
IPropertyReflectionAwareModelgetPropertySetter in interface IPropertyReflectionAwareModel<T>IPropertyReflectionAwareModel.getPropertySetter()protected abstract String propertyExpression()
public final Object getInnermostModelOrObject()
Copyright © 2006–2014 Apache Software Foundation. All rights reserved.