Package org.eclipse.jetty.util.thread
Class TimerScheduler
- java.lang.Object
-
- org.eclipse.jetty.util.component.AbstractLifeCycle
-
- org.eclipse.jetty.util.thread.TimerScheduler
-
public class TimerScheduler extends AbstractLifeCycle implements Scheduler, java.lang.Runnable
A scheduler based on the the JVM Timer class
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from class org.eclipse.jetty.util.component.AbstractLifeCycle
AbstractLifeCycle.AbstractLifeCycleListener
-
Nested classes/interfaces inherited from interface org.eclipse.jetty.util.component.LifeCycle
LifeCycle.Listener
-
Nested classes/interfaces inherited from interface org.eclipse.jetty.util.thread.Scheduler
Scheduler.Task
-
-
Constructor Summary
Constructors Constructor Description TimerScheduler()
TimerScheduler(java.lang.String name, boolean daemon)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description protected void
doStart()
protected void
doStop()
void
run()
Scheduler.Task
schedule(java.lang.Runnable task, long delay, java.util.concurrent.TimeUnit units)
-
Methods inherited from class org.eclipse.jetty.util.component.AbstractLifeCycle
addLifeCycleListener, getState, getState, getStopTimeout, isFailed, isRunning, isStarted, isStarting, isStopped, isStopping, removeLifeCycleListener, setStopTimeout, start, stop, toString
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
-
Methods inherited from interface org.eclipse.jetty.util.component.LifeCycle
addLifeCycleListener, isFailed, isRunning, isStarted, isStarting, isStopped, isStopping, removeLifeCycleListener, start, stop
-
-
-
-
Method Detail
-
doStart
protected void doStart() throws java.lang.Exception
- Overrides:
doStart
in classAbstractLifeCycle
- Throws:
java.lang.Exception
-
doStop
protected void doStop() throws java.lang.Exception
- Overrides:
doStop
in classAbstractLifeCycle
- Throws:
java.lang.Exception
-
schedule
public Scheduler.Task schedule(java.lang.Runnable task, long delay, java.util.concurrent.TimeUnit units)
-
run
public void run()
- Specified by:
run
in interfacejava.lang.Runnable
-
-