| 
 | |||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||
java.lang.Objectmx4j.timer.TimeTask
A task that is executed at a specified time.
Subclasses implement the periodicity, if needed. Two TimeTasks are compared with their neext execution time.
| Constructor Summary | |
| protected  | TimeTask()Constructor for subclasses | 
| Method Summary | |
|  int | compareTo(java.lang.Object obj)Compares 2 TimeTasks by comparing their next execution times | 
|  boolean | getFixedRate()Returns whether this task is a fixed rate or fixed delay task. | 
| protected  long | getNextExecutionTime()Returns the next time at which the task will be executed, ie the run()method is called. | 
| protected  long | getPeriod()Returns the period of this task. | 
| protected  boolean | isFinished()Returns whethere this task is finished. | 
| protected  boolean | isPeriodic()Returns whether this task is periodic. | 
| abstract  void | run()The method to implement to have this TimeTask to do something. | 
| protected  void | setFinished(boolean value)Marks this task as finished or not. | 
| protected  void | setNextExecutionTime(long time)Sets the next execution time. | 
| Methods inherited from class java.lang.Object | 
| clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait | 
| Constructor Detail | 
protected TimeTask()
| Method Detail | 
public abstract void run()
run in interface java.lang.Runnableprotected boolean isPeriodic()
getPeriod()protected long getPeriod()
isPeriodic()public boolean getFixedRate()
protected long getNextExecutionTime()
run() method is called.
setNextExecutionTime(long)protected void setNextExecutionTime(long time)
getNextExecutionTime()protected void setFinished(boolean value)
run() method will not be called anymore.
isFinished()protected boolean isFinished()
setFinished(boolean)public int compareTo(java.lang.Object obj)
compareTo in interface java.lang.ComparablegetNextExecutionTime()| 
 | |||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||