|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object java.util.Dictionary<K,V> java.util.Hashtable<Object,Object> java.util.Properties org.eigenbase.util.property.TriggerableProperties
public class TriggerableProperties
Base class for properties which can respond to triggers.
If you wish to be notified of changes to properties, use the Property.addTrigger(Trigger)
method to register a callback.
Field Summary | |
---|---|
protected Map |
properties
|
protected Map |
triggers
|
Fields inherited from class java.util.Properties |
---|
defaults |
Constructor Summary | |
---|---|
protected |
TriggerableProperties()
|
Method Summary | |
---|---|
(package private) static boolean |
equals(Object o1,
Object o2)
|
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. |
private void |
superSetProperty(String key,
String oldValue)
This is ONLY called during a veto operation. |
boolean |
triggersAreEnabled()
Whether triggers are enabled. |
Methods inherited from class java.util.Properties |
---|
getProperty, getProperty, list, list, load, loadFromXML, propertyNames, save, store, storeToXML, storeToXML |
Methods inherited from class java.util.Hashtable |
---|
clear, clone, contains, containsKey, containsValue, elements, entrySet, equals, get, hashCode, isEmpty, keys, keySet, put, putAll, rehash, remove, size, toString, values |
Methods inherited from class java.lang.Object |
---|
finalize, getClass, notify, notifyAll, wait, wait, wait |
Field Detail |
---|
protected final Map triggers
protected final Map properties
Constructor Detail |
---|
protected TriggerableProperties()
Method Detail |
---|
public Object setProperty(String key, String value)
If the previous value does not equal the new value, executes any
Trigger
s associated with the property, in order of their phase
.
setProperty
in class Properties
key
- Name of propertyvalue
- Value
public boolean triggersAreEnabled()
public Property getPropertyDefinition(String path)
path
- Name of the property
private void superSetProperty(String key, String oldValue)
setProperty(java.lang.String, java.lang.String)
.
key
- Property nameoldValue
- Previous value of propertystatic boolean equals(Object o1, Object o2)
public void register(Property property)
public Collection getProperties()
public List getPropertyList()
Property
.
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |