de.intarsys.tools.event
Class CommonNotificationSupport

java.lang.Object
  extended by de.intarsys.tools.event.CommonNotificationSupport
All Implemented Interfaces:
INotificationSupport

public class CommonNotificationSupport
extends java.lang.Object
implements INotificationSupport

A convenience implementation to plugin INotificationSupport.


Constructor Summary
CommonNotificationSupport()
           
 
Method Summary
 void addNotificationListener(EventType type, INotificationListener listener)
          Add listener to the collection of objects to be informed when the receiver triggers an event of type name.
protected  void markDirty(java.lang.Object attribute, java.lang.Object oldValue, java.lang.Object newValue)
           
 void removeNotificationListener(EventType type, INotificationListener listener)
          Remove listener from the collection of objects to be informed about events of type name.
protected  void triggerChanged(java.lang.Object attribute, java.lang.Object oldValue, java.lang.Object newValue)
           
protected  void triggerChangedBasic(java.lang.Object attribute, java.lang.Object oldValue, java.lang.Object newValue)
           
protected  void triggerEvent(Event event)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

CommonNotificationSupport

public CommonNotificationSupport()
Method Detail

addNotificationListener

public void addNotificationListener(EventType type,
                                    INotificationListener listener)
Description copied from interface: INotificationSupport
Add listener to the collection of objects to be informed when the receiver triggers an event of type name.

Specified by:
addNotificationListener in interface INotificationSupport
Parameters:
type - The event type we are interested in.
listener - The object to be informed about an event occurrence

markDirty

protected void markDirty(java.lang.Object attribute,
                         java.lang.Object oldValue,
                         java.lang.Object newValue)

removeNotificationListener

public void removeNotificationListener(EventType type,
                                       INotificationListener listener)
Description copied from interface: INotificationSupport
Remove listener from the collection of objects to be informed about events of type name.

Specified by:
removeNotificationListener in interface INotificationSupport
Parameters:
type - The event type we are no longer interested in.
listener - The object registered for the event till now.

triggerChanged

protected void triggerChanged(java.lang.Object attribute,
                              java.lang.Object oldValue,
                              java.lang.Object newValue)

triggerChangedBasic

protected void triggerChangedBasic(java.lang.Object attribute,
                                   java.lang.Object oldValue,
                                   java.lang.Object newValue)

triggerEvent

protected void triggerEvent(Event event)