public static class Preferences.PropertyChangeEvent extends EventObject
The preferences object reports property change events for internal state
changes that may be of interest to external parties. A special listener
interface (Preferences.IPropertyChangeListener
) is
defined for this purpose. Listeners are registered via the
Preferences.addPropertyChangeListener
method.
Clients cannot instantiate or subclass this class.
source
Modifier | Constructor and Description |
---|---|
protected |
PropertyChangeEvent(Object source,
String property,
Object oldValue,
Object newValue)
Creates a new property change event.
|
Modifier and Type | Method and Description |
---|---|
Object |
getNewValue()
Returns the new value of the property.
|
Object |
getOldValue()
Returns the old value of the property.
|
String |
getProperty()
Returns the name of the property that changed.
|
getSource, toString
protected PropertyChangeEvent(Object source, String property, Object oldValue, Object newValue)
source
- the object whose property has changedproperty
- the property that has changed (must not be
null
)oldValue
- the old value of the property, or
null
if nonenewValue
- the new value of the property, or
null
if nonepublic String getProperty()
Warning: there is no guarantee that the property name returned
is a constant string. Callers must compare property names using
equals
, not ==.
public Object getNewValue()
null
if not known
or not relevantpublic Object getOldValue()
null
if not known
or not relevant
Copyright (c) 2000, 2015 Eclipse Contributors and others. All rights reserved.Guidelines for using Eclipse APIs.