public interface PropertyHolder
Property| Modifier and Type | Method and Description |
|---|---|
java.util.Map<java.lang.String,Property> |
getProperties()
Returns a mapping between every property name and the corresponding property.
|
void |
propertyChanged(Property property)
This method will be called after the given
Property's value
has changed. |
boolean |
validatePropertyChange(Property property,
java.lang.Object value)
This method allows the
PropertyHolder to veto whether or not the
given Property should change to the given value. |
java.util.Map<java.lang.String,Property> getProperties()
boolean validatePropertyChange(Property property, java.lang.Object value)
PropertyHolder to veto whether or not the
given Property should change to the given value.
It is called whenever setValue(...)
is called.
It is called only when the value if the value is acceptable.
In other words, it must not be null and it must correspond to
the type of element that the Property accepts. So if the given
Property is an IntegerProperty, then value will
be a non-null Integer object.
Note that this method will not be called when a property receives its value from a save file
property - the Propertyvalue - the value to change it tovoid propertyChanged(Property property)
Property's value
has changed.property - the Property that changed