|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object java.util.TimerTask org.apache.camel.processor.resequencer.Timeout
public class Timeout
A timer task that notifies handlers about scheduled timeouts.
Timer
,
TimerTask
Constructor Summary | |
---|---|
Timeout(Timer timer,
long timeout)
Creates a new timeout task using the given Timer instance and
timeout value. |
Method Summary | |
---|---|
TimeoutHandler |
getTimeoutHandlers()
Returns the timeout handler that has been registered for notification. |
void |
run()
Notifies the timeout handler about the scheduled timeout. |
void |
schedule()
Schedules this timeout task. |
void |
setTimeoutHandler(TimeoutHandler timeoutHandler)
Sets a timeout handler for receiving timeout notifications. |
Methods inherited from class java.util.TimerTask |
---|
cancel, scheduledExecutionTime |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public Timeout(Timer timer, long timeout)
Timer
instance and
timeout value. The task is not scheduled immediately. It will be
scheduled by calling this task's schedule()
method.
timer
- a timertimeout
- a timeout value.Method Detail |
---|
public TimeoutHandler getTimeoutHandlers()
public void setTimeoutHandler(TimeoutHandler timeoutHandler)
timeoutHandler
- a timeout handler.public void schedule()
public void run()
run
in interface Runnable
run
in class TimerTask
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |