org.hibersap.util
Class Announcer<T>

java.lang.Object
  extended by org.hibersap.util.Announcer<T>
Type Parameters:
T - The Listener's type

public class Announcer<T>
extends Object

Handles Listener logic.

Stolen and modified from the examples of the book "Growing Object-Oriented Software, Guided by Tests" by Freeman/Pryce. See https://github.com/sf105/goos-code.


Method Summary
 void addAllListeners(Collection<T> listeners)
           
 void addListener(T listener)
           
 T announce()
           
 void removeListener(T listener)
           
static
<T> Announcer<T>
to(Class<? extends T> listenerType)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Method Detail

addListener

public void addListener(T listener)

addAllListeners

public void addAllListeners(Collection<T> listeners)

removeListener

public void removeListener(T listener)

announce

public T announce()

to

public static <T> Announcer<T> to(Class<? extends T> listenerType)


Copyright © 2011 akquinet tech@spree GmbH. All Rights Reserved.