public interface TimerManager
Modifier and Type | Method and Description |
---|---|
boolean |
isRunning()
Checks if manager is running.
|
TimerHandle |
schedule(TimerTask task,
long delay,
long interval)
Submits one timer task to execute periodically.
|
TimerHandle |
scheduleAtFixedRate(TimerTask task,
long delay,
long interval)
Submits one timer task to execute periodically at fixed rate.
|
void |
start()
Starts timer manager and prepares it to work.
|
void |
stop()
Shuts timer manager down and cleans everything up.
|
void start()
boolean isRunning()
TimerHandle schedule(TimerTask task, long delay, long interval)
task
- task to execute.delay
- delay to start task
in milliseconds.interval
- task invocation interval
in milliseconds.TimerHandle scheduleAtFixedRate(TimerTask task, long delay, long interval)
task
- task to execute.delay
- delay to start task
in milliseconds.interval
- task invocation interval
in milliseconds.void stop()
Copyright © 2008, 2017, Oracle. All rights reserved.