限定符和类型 | 方法和说明 |
---|---|
boolean |
cancel()
Attempts to cancel the
TimerTask associated with this handle. |
boolean |
isCancelled()
Returns
true if and only if the TimerTask associated
with this handle has been cancelled. |
boolean |
isExpired()
Returns
true if and only if the TimerTask associated
with this handle has been expired. |
TimerTask |
task()
Returns the
TimerTask which is associated with this handle. |
Timer |
timer()
Returns the
Timer that created this handle. |
boolean isExpired()
true
if and only if the TimerTask
associated
with this handle has been expired.boolean isCancelled()
true
if and only if the TimerTask
associated
with this handle has been cancelled.boolean cancel()
TimerTask
associated with this handle.
If the task has been executed or cancelled already, it will return with
no side effect.