|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--com.caucho.util.Cron
The cron class provides a lightweight event scheduler. This allows an objects to schedule a timeout without creating a new thread.
Cron should be used for slower requests.
A separate thread periodically tests the queue for crons ready.
Constructor Summary | |
Cron(CronListener listener)
Create a new wakeup cron with a designated listener as a callback. |
|
Cron(CronListener listener,
java.lang.String name)
Create a new wakeup cron with a designated listener as a callback. |
Method Summary | |
void |
dequeue()
Remove the cron from the wakeup queue. |
CronListener |
getListener()
Return the cron's listener. |
void |
queue()
Queue the cron for wakeup. |
void |
setListener(CronListener listener)
Sets the cron's listener. |
java.lang.String |
toString()
|
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Constructor Detail |
public Cron(CronListener listener, java.lang.String name)
public Cron(CronListener listener)
Method Detail |
public CronListener getListener()
public void setListener(CronListener listener)
public void queue()
public void dequeue()
public java.lang.String toString()
toString
in class java.lang.Object
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |