Package ucar.unidata.beans
Class PropertySet
java.lang.Object
ucar.unidata.beans.PropertySet
- All Implemented Interfaces:
Serializable
Provides support for JavaBean properties.
- Author:
- Steven R. Emmerson
- See Also:
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidaddProperty(Property property) Adds a property to the collection of properties.voidAdds a property change listener for all properties in the set.voidaddPropertyChangeListener(String name, PropertyChangeListener listener) Adds a property change listener for a named property.voidAdds a vetoable property change listener for all vetoable properties in the set.voidaddVetoableChangeListener(String name, VetoableChangeListener listener) Adds a vetoable property change listener for a named vetoable property.voidDisables the reporting of property changes.voidEnables the reporting of property changes.getProperty(String name) Gets a property by name from the collection of properties.voidremoveProperty(Property property) Removes a property from the collection of properties.voidRemoves a property change listener for all properties in the set.voidremovePropertyChangeListener(String name, PropertyChangeListener listener) Removes a property change listener for a named property.voidRemoves a vetoable property change listener for all vetoable properties in the set.voidremoveVetoableChangeListener(String name, VetoableChangeListener listener) Removes a vetoable property change listener for a named vetoable property.
-
Constructor Details
-
PropertySet
public PropertySet()
-
-
Method Details
-
addProperty
Adds a property to the collection of properties.- Parameters:
property- some property
-
removeProperty
Removes a property from the collection of properties.- Parameters:
property- some property
-
getProperty
Gets a property by name from the collection of properties.- Parameters:
name- The name of the property.- Returns:
- The Property corresponding to
name.
-
disablePropertyChangeEvents
public void disablePropertyChangeEvents()Disables the reporting of property changes. After invoking this method, all subsequent property change events will be deferred until the methodenablePropertyChangeEvents()is invoked. -
enablePropertyChangeEvents
public void enablePropertyChangeEvents()Enables the reporting of property changes. All deferred property change events will be reported as well as all subsequent events until the next invocation ofdisablePropertyChangeEvents(). -
addPropertyChangeListener
Adds a property change listener for all properties in the set.- Parameters:
listener- The property change listener.
-
removePropertyChangeListener
Removes a property change listener for all properties in the set.- Parameters:
listener- The property change listener.
-
addPropertyChangeListener
Adds a property change listener for a named property.- Parameters:
name- The name of the property.listener- The property change listener.
-
removePropertyChangeListener
Removes a property change listener for a named property.- Parameters:
name- The name of the property.listener- The property change listener.
-
addVetoableChangeListener
Adds a vetoable property change listener for all vetoable properties in the set.- Parameters:
listener- The vetoable property change listener.
-
removeVetoableChangeListener
Removes a vetoable property change listener for all vetoable properties in the set.- Parameters:
listener- The vetoable property change listener.
-
addVetoableChangeListener
Adds a vetoable property change listener for a named vetoable property. If the named property is not vetoable, then nothing happens.- Parameters:
name- The name of the vetoable property.listener- The vetoable property change listener.
-
removeVetoableChangeListener
Removes a vetoable property change listener for a named vetoable property. If the named property is not vetoable, then nothing happens.- Parameters:
name- The name of the vetoable property.listener- The vetoable property change listener.
-