|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
public interface EventDispatcher
Dispatches all events from the library internals to all registered listeners. Note: Implementations check for listeners who cause event loops, and temporary exclude these from event delivery to prevent endless loops.
| Field Summary | |
|---|---|
static int |
PRI_HIGH
|
static int |
PRI_LOW
|
static int |
PRI_NORMAL
|
static int |
PRI_SYSTEM_HIGH
|
static int |
PRI_SYSTEM_LOW
|
| Method Summary | |
|---|---|
void |
notify(PersistenceEvent event)
Notify all listeners of given event. |
boolean |
notifyAll(PersistenceEvent event)
Notify all listeners in a guaranteed way. |
void |
registerListener(PersistenceEventListener listener)
Register the given listener to this dispatcher. |
void |
registerListener(PersistenceEventListener listener,
int priority)
Register the given listener to this dispatcher with a priority. |
void |
unregisterListener(PersistenceEventListener listener)
Remove the given listener from this dispatcher. |
| Field Detail |
|---|
static final int PRI_SYSTEM_LOW
static final int PRI_LOW
static final int PRI_NORMAL
static final int PRI_HIGH
static final int PRI_SYSTEM_HIGH
| Method Detail |
|---|
void registerListener(PersistenceEventListener listener)
void registerListener(PersistenceEventListener listener,
int priority)
priority - The priority of the listener. The lower the earlier
the listener gets called. This has to be between PRI_LOW,
and PRI_HIGH inclusive.void unregisterListener(PersistenceEventListener listener)
void notify(PersistenceEvent event)
throws java.lang.Exception
java.lang.Exception - The event handlers' exception is forwarded as-is.boolean notifyAll(PersistenceEvent event)
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||