|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectjava.util.TimerTask
ui.Stopwatch
public class Stopwatch
Constructor Summary | |
---|---|
Stopwatch(long millisLeft)
|
Method Summary | |
---|---|
void |
addStopwatchListener(StopwatchListener s)
Adds a StopwatchListener to this. |
protected void |
fireTimeChanged()
Informs all of this Stopwatch's listeners that its time is decreasing |
long |
getTime()
Returns the amount of time left on the Stopwatch (or zero, if that time is less than zero). |
void |
removeStopwatchListener(StopwatchListener s)
Removes a StopwatchListener from this |
void |
run()
Informs all of this Stopwatch's listeners that its time is decreasing |
void |
start()
Starts the timer, if it was not already running. |
void |
stop()
Stops the timer, if it was not already stopped. |
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 Stopwatch(long millisLeft)
Method Detail |
---|
public void start()
public void stop()
public long getTime()
public void addStopwatchListener(StopwatchListener s)
public void removeStopwatchListener(StopwatchListener s)
protected void fireTimeChanged()
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 |