wicket.util.listener
Class ListenerSet

java.lang.Object
  extended bywicket.util.listener.ListenerSet
Direct Known Subclasses:
ChangeListenerSet

public abstract class ListenerSet
extends java.lang.Object

Holds a set of listeners implementing the IListener tag interface. Subclasses can implement notification methods that cast the listener to the correct subinterface and invoke the appropriate listener method.

Author:
Jonathan Locke

Constructor Summary
ListenerSet()
           
 
Method Summary
 void add(IListener listener)
          Adds a listener to this set of listeners.
protected abstract  void notifyListener(IListener listener)
          Notifies a listener.
 void notifyListeners()
          Notifies each listener in this set by calling notifyListener.
 void remove(IListener listener)
          Removes a listener from this set.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

ListenerSet

public ListenerSet()
Method Detail

add

public void add(IListener listener)
Adds a listener to this set of listeners.

Parameters:
listener - The listener to add

notifyListeners

public void notifyListeners()
Notifies each listener in this set by calling notifyListener.


remove

public void remove(IListener listener)
Removes a listener from this set.

Parameters:
listener - The listener to remove

notifyListener

protected abstract void notifyListener(IListener listener)
Notifies a listener.

Parameters:
listener - The listener to notify


Copyright © 2004-2005 Wicket developers. All Rights Reserved.