activemq-cpp-3.6.0
|
Scheduler class for use in executing Runnable Tasks either periodically or one time only with optional delay. More...
#include <src/main/activemq/threads/Scheduler.h>
Public Member Functions | |
Scheduler (const std::string &name) | |
virtual | ~Scheduler () |
void | executePeriodically (decaf::lang::Runnable *task, long long period, bool ownsTask=true) |
void | schedualPeriodically (decaf::lang::Runnable *task, long long period, bool ownsTask=true) |
void | cancel (decaf::lang::Runnable *task) |
void | executeAfterDelay (decaf::lang::Runnable *task, long long delay, bool ownsTask=true) |
void | shutdown () |
![]() | |
ServiceSupport (const ServiceSupport &) | |
ServiceSupport & | operator= (const ServiceSupport &) |
ServiceSupport () | |
virtual | ~ServiceSupport () |
void | start () |
Starts the Service, notifying any registered listeners of the start if it is successful. | |
void | stop () |
Stops the Service. | |
bool | isStarted () const |
bool | isStopping () const |
bool | isStopped () const |
void | addServiceListener (ServiceListener *listener) |
Adds the given listener to this Service's list of listeners, call retains ownership of the pointer. | |
void | removeServiceListener (ServiceListener *llistener) |
Removes the given listener to this Service's list of listeners, call retains ownership of the pointer. | |
![]() | |
virtual | ~Service () |
Protected Member Functions | |
virtual void | doStart () |
Performs the actual start operation on the service, acquiring all the resources needed to run the service. | |
virtual void | doStop (activemq::util::ServiceStopper *stopper) |
Performs the actual stop operation on the service, ensuring that all resources held are released, must be implemented in derived class. |
Additional Inherited Members | |
![]() | |
static void | dispose (Service *service) |
Safely shuts down a service. |
Scheduler class for use in executing Runnable Tasks either periodically or one time only with optional delay.
activemq::threads::Scheduler::Scheduler | ( | const std::string & | name | ) |
|
virtual |
void activemq::threads::Scheduler::cancel | ( | decaf::lang::Runnable * | task | ) |
|
protectedvirtual |
Performs the actual start operation on the service, acquiring all the resources needed to run the service.
Must be implemented in derived class.
Implements activemq::util::ServiceSupport.
|
protectedvirtual |
Performs the actual stop operation on the service, ensuring that all resources held are released, must be implemented in derived class.
Implements activemq::util::ServiceSupport.
void activemq::threads::Scheduler::executeAfterDelay | ( | decaf::lang::Runnable * | task, |
long long | delay, | ||
bool | ownsTask = true |
||
) |
void activemq::threads::Scheduler::executePeriodically | ( | decaf::lang::Runnable * | task, |
long long | period, | ||
bool | ownsTask = true |
||
) |
void activemq::threads::Scheduler::schedualPeriodically | ( | decaf::lang::Runnable * | task, |
long long | period, | ||
bool | ownsTask = true |
||
) |
void activemq::threads::Scheduler::shutdown | ( | ) |