|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.exoplatform.services.listener.ListenerService
public class ListenerService
Created by The eXo Platform SAS Author : Nhu Dinh Thuan nhudinhthuan@exoplatform.com Apr 6, 2007
| Constructor Summary | |
|---|---|
ListenerService()
Construct a listener service. |
|
| Method Summary | ||
|---|---|---|
void |
addListener(Listener listener)
This method is used to register a listener with the service. |
|
void |
addListener(String eventName,
Listener listener)
Deprecated. use the Listener name as the event name |
|
|
broadcast(String name,
S source,
D data)
This method is used to broadcast an event. |
|
|
broadcast(T event)
This method is used when a developer want to implement his own event object and broadcast the event. |
|
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public ListenerService()
| Method Detail |
|---|
public void addListener(Listener listener)
listener -
public void addListener(String eventName,
Listener listener)
eventName - listener -
public final <S,D> void broadcast(String name,
S source,
D data)
throws Exception
S - The type of the source that broacast the eventD - The type of the data that the source object is working onname - The name of the eventsource - The source object instancedata - The data object instance
Exception - TODO: Should not delegate to the method broadcast(Event)
public final <T extends Event> void broadcast(T event)
throws Exception
T - The type of the event object, the type of the event object has
to be extended from the Event typeevent - The event instance
Exception
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||