Class NotificationManager
java.lang.Object
org.eclipse.handly.model.impl.support.NotificationManager
- All Implemented Interfaces:
INotificationManager
Default implementation of
INotificationManager
. Thread-safe.
Clients can use this class as it stands or subclass it as circumstances warrant.
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionvoid
Adds the given element change listener.void
addElementChangeListener
(IElementChangeListener listener, int eventMask) Adds the given element change listener for the specified event types.void
Notifies registered listeners about the given event.void
Removes the given element change listener.
-
Constructor Details
-
NotificationManager
public NotificationManager()
-
-
Method Details
-
addElementChangeListener
Adds the given element change listener. Has no effect if an identical listener is already registered.- Parameters:
listener
- the listener to add (notnull
)- See Also:
-
addElementChangeListener
Adds the given element change listener for the specified event types. Has no effect if an identical listener is already registered for these event types.After completion of this method, the given listener will be registered for exactly the specified event types. If it was previously registered for other event types, it will be de-registered for those event types.
- Parameters:
listener
- the listener to add (notnull
)eventMask
- the bit-wise OR of all event types of interest to the listener- See Also:
-
removeElementChangeListener
Removes the given element change listener. Has no effect if an identical listener is not registered.- Parameters:
listener
- the listener to remove (notnull
)
-
fireElementChangeEvent
Description copied from interface:INotificationManager
Notifies registered listeners about the given event.- Specified by:
fireElementChangeEvent
in interfaceINotificationManager
- Parameters:
event
- an element change event (notnull
)
-