Package org.apache.activemq.thread
Class Scheduler
- java.lang.Object
-
- org.apache.activemq.util.ServiceSupport
-
- org.apache.activemq.thread.Scheduler
-
- All Implemented Interfaces:
Service
public final class Scheduler extends ServiceSupport
-
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
cancel(Runnable task)
protected void
doStart()
protected void
doStop(ServiceStopper stopper)
void
executeAfterDelay(Runnable task, long redeliveryDelay)
void
executePeriodically(Runnable task, long period)
String
getName()
void
shutdown()
-
Methods inherited from class org.apache.activemq.util.ServiceSupport
addServiceListener, dispose, isStarted, isStopped, isStopping, postStop, preStart, removeServiceListener, start, stop
-
-
-
-
Constructor Detail
-
Scheduler
public Scheduler(String name)
-
-
Method Detail
-
executePeriodically
public void executePeriodically(Runnable task, long period)
-
cancel
public void cancel(Runnable task)
-
executeAfterDelay
public void executeAfterDelay(Runnable task, long redeliveryDelay)
-
shutdown
public void shutdown()
-
doStart
protected void doStart() throws Exception
- Specified by:
doStart
in classServiceSupport
- Throws:
Exception
-
doStop
protected void doStop(ServiceStopper stopper) throws Exception
- Specified by:
doStop
in classServiceSupport
- Throws:
Exception
-
getName
public String getName()
-
-