|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.d_haven.event.impl.AbstractEventHandler
org.d_haven.event.command.CommandEventHandler
The CommandEventHandler is used by the DefaultCommandManager to actually process the events. It is from this location that we run the commands and reschedule them as needed.
Constructor Summary | |
CommandEventHandler(CommandFailureHandler failureHandler,
SwitchedEnqueuePredicate predicate)
Create the CommandEventHandler with the failure handler and the predicate provided. |
Method Summary | |
CommandFailureHandler |
getCommandFailureHandler()
Get the CommandFailureHandler in use for this event handler. |
void |
handleEvent(java.lang.Object element)
Handle one event at a time. |
void |
setCommandEventPipeline(CommandEventPipeline pipeline)
Provide the CommandEventPipeline to use for requeueing delayed and repeating commands. |
void |
setCommandFailureHandler(CommandFailureHandler handler)
Set the CommandFailureHandler to use with this event handler. |
java.lang.String |
toString()
Provide a debug string for this class. |
Methods inherited from class org.d_haven.event.impl.AbstractEventHandler |
handleEvents |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Constructor Detail |
public CommandEventHandler(CommandFailureHandler failureHandler, SwitchedEnqueuePredicate predicate)
failureHandler
- The CommandFailureHandler used when a
command failspredicate
- The predicate used to determine if we are
accepting new commandsMethod Detail |
public void setCommandEventPipeline(CommandEventPipeline pipeline)
pipeline
- The pipeline to use for processingpublic void handleEvent(java.lang.Object element)
EventHandler
element
- The element that the EventHandler must processpublic java.lang.String toString()
public CommandFailureHandler getCommandFailureHandler()
public void setCommandFailureHandler(CommandFailureHandler handler)
handler
- the new handler
|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |