    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 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

Submit a bug or feature - Version 1.1.8 of Java Platform API Specification
Java is a trademark or registered trademark of Sun Microsystems, Inc. in the US and other countries.
Copyright 1995-1999 Sun Microsystems, Inc. 901 San Antonio Road,
Palo Alto, California, 94303, U.S.A. All Rights Reserved.