All Packages Class Hierarchy This Package Previous Next Index
Class java.beans.PropertyChangeSupport
java.lang.Object
|
+----java.beans.PropertyChangeSupport
- public class PropertyChangeSupport
- extends Object
- implements Serializable
This is a utility class that can be used by beans that support bound
properties. You can either inherit from this class or you can use
an instance of this class as a member field of your bean and delegate
various work to it.
-
PropertyChangeSupport(Object)
-
-
addPropertyChangeListener(PropertyChangeListener)
- Add a PropertyChangeListener to the listener list.
-
firePropertyChange(String, Object, Object)
- Report a bound property update to any registered listeners.
-
removePropertyChangeListener(PropertyChangeListener)
- Remove a PropertyChangeListener from the listener list.
PropertyChangeSupport
public PropertyChangeSupport(Object sourceBean)
addPropertyChangeListener
public synchronized void addPropertyChangeListener(PropertyChangeListener listener)
- Add a PropertyChangeListener to the listener list.
- Parameters:
- listener - The PropertyChangeListener to be added
removePropertyChangeListener
public synchronized void removePropertyChangeListener(PropertyChangeListener listener)
- Remove a PropertyChangeListener from the listener list.
- Parameters:
- listener - The PropertyChangeListener to be removed
firePropertyChange
public void firePropertyChange(String propertyName,
Object oldValue,
Object newValue)
- Report a bound property update to any registered listeners.
No event is fired if old and new are equal and non-null.
- Parameters:
- propertyName - The programmatic name of the property
that was changed.
- oldValue - The old value of the property.
- newValue - The new value of the property.
All Packages Class Hierarchy This Package Previous Next Index