public class TriggerableProperties extends Properties
If you wish to be notified of changes to properties, use the Property.addTrigger(Trigger) method to register a callback.
| Modifier and Type | Field and Description |
|---|---|
protected Map |
properties |
protected Map |
triggers |
defaults| Modifier | Constructor and Description |
|---|---|
protected |
TriggerableProperties() |
| Modifier and Type | Method and Description |
|---|---|
Collection |
getProperties()
Returns a collection of registered properties.
|
Property |
getPropertyDefinition(String path)
Returns the definition of a named property, or null if there is no such
property.
|
List |
getPropertyList()
Returns a list of every
Property. |
void |
register(Property property)
Registers a property with this properties object to make it available for
callbacks.
|
Object |
setProperty(String key,
String value)
Sets the value of a property.
|
boolean |
triggersAreEnabled()
Whether triggers are enabled.
|
getProperty, getProperty, list, list, load, load, loadFromXML, propertyNames, save, store, store, storeToXML, storeToXML, stringPropertyNamespublic Object setProperty(String key, String value)
If the previous value does not equal the new value, executes any
Triggers associated with the property, in order of their phase.
setProperty in class Propertieskey - Name of propertyvalue - Valuepublic boolean triggersAreEnabled()
public Property getPropertyDefinition(String path)
path - Name of the propertypublic void register(Property property)
public Collection getProperties()
Copyright © 2012–2015 Julian Hyde. All rights reserved.