ValueProvider, Setter, see
Binder@Deprecated public class NestedMethodProperty<T> extends AbstractProperty<T>
MethodProperty,
Serialized FormAbstractProperty.ReadOnlyStatusChangeEventProperty.Editor, Property.ReadOnlyException, Property.ReadOnlyStatusChangeListener, Property.ReadOnlyStatusChangeNotifier, Property.Transactional<T>, Property.ValueChangeListener, Property.ValueChangeNotifier, Property.Viewer| Constructor and Description |
|---|
NestedMethodProperty(Object instance,
String propertyName)
Deprecated.
Constructs a nested method property for a given object instance.
|
| Modifier and Type | Method and Description |
|---|---|
protected List<Method> |
getGetMethods()
Deprecated.
Returns an unmodifiable list of getter methods to call in sequence to get
the property value.
|
Object |
getInstance()
Deprecated.
The instance used by this property.
|
Class<? extends T> |
getType()
Deprecated.
Returns the type of the Property.
|
T |
getValue()
Deprecated.
Gets the value stored in the Property.
|
protected void |
invokeSetMethod(T value)
Deprecated.
Internal method to actually call the setter method of the wrapped
property.
|
boolean |
isReadOnly()
Deprecated.
Tests if the Property is in read-only mode.
|
void |
setInstance(Object instance)
Deprecated.
Sets the instance used by this property.
|
void |
setValue(T newValue)
Deprecated.
Sets the value of the property.
|
addListener, addListener, addReadOnlyStatusChangeListener, addValueChangeListener, fireReadOnlyStatusChange, fireValueChange, getListeners, removeListener, removeListener, removeReadOnlyStatusChangeListener, removeValueChangeListener, setReadOnlypublic NestedMethodProperty(Object instance, String propertyName)
Calling getValue will return null if any intermediate getter returns null
instance - top-level bean to which the property appliespropertyName - dot separated nested property nameIllegalArgumentException - if the property name is invalidpublic Class<? extends T> getType()
PropertygetValue and
setValue must be compatible with this type: one must be able
to safely cast the value returned from getValue to the given
type and pass any variable assignable to this type as an argument to
setValue.public boolean isReadOnly()
AbstractPropertysetValue will throw
ReadOnlyException and will not modify the value of the
Property.
Override for additional restrictions on what is considered a read-only
property.isReadOnly in interface Property<T>isReadOnly in class AbstractProperty<T>true if the Property is in read-only mode,
false if it's notpublic T getValue()
getInstance()public void setValue(T newValue) throws Property.ReadOnlyException
newValue - the New value of the property.Property.ReadOnlyException - if the object is in read-only mode.Property.ReadOnlyException - if the object is in read-only modeinvokeSetMethod(Object)protected void invokeSetMethod(T value)
value - protected List<Method> getGetMethods()
public Object getInstance()
public void setInstance(Object instance)
The new instance must be of the same type as the old instance
To be consistent with setValue(Object), this method will fire a
value change event even if the value stays the same
instance - the instance to useCopyright © 2019 Vaadin Ltd. All rights reserved.