Package java.util.prefs
Class NodeChangeEvent
- java.lang.Object
-
- java.util.EventObject
-
- java.util.prefs.NodeChangeEvent
-
- All Implemented Interfaces:
Serializable
public class NodeChangeEvent extends EventObject implements Serializable
This is the event class to indicate that one child of the preference node has been added or deleted.Please note that although the class is marked as
Serializableby inheritance fromEventObject, this type is not intended to be serialized so the serialization methods do nothing but throw aNotSerializableException.- Since:
- 1.4
- See Also:
Preferences,NodeChangeListener, Serialized Form
-
-
Field Summary
-
Fields inherited from class java.util.EventObject
source
-
-
Constructor Summary
Constructors Constructor Description NodeChangeEvent(Preferences p, Preferences c)Constructs a newNodeChangeEventinstance.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description PreferencesgetChild()Gets the childPreferencesnode that was added or removed.PreferencesgetParent()Gets thePreferencesinstance that fired this event.-
Methods inherited from class java.util.EventObject
getSource, toString
-
-
-
-
Constructor Detail
-
NodeChangeEvent
public NodeChangeEvent(Preferences p, Preferences c)
Constructs a newNodeChangeEventinstance.- Parameters:
p- thePreferencesinstance that fired this event; this object is considered as the event source.c- the childPreferencesinstance that was added or deleted.
-
-
Method Detail
-
getParent
public Preferences getParent()
Gets thePreferencesinstance that fired this event.- Returns:
- the
Preferencesinstance that fired this event.
-
getChild
public Preferences getChild()
Gets the childPreferencesnode that was added or removed.- Returns:
- the added or removed child
Preferencesnode.
-
-