|
activemq-cpp-3.9.5
|
A Task Runner that can contain one or more CompositeTasks that are each checked for pending work and run if any is present in the order that the tasks were added. More...
#include <src/main/activemq/threads/CompositeTaskRunner.h>

Public Member Functions | |
| CompositeTaskRunner () | |
| virtual | ~CompositeTaskRunner () |
| virtual void | start () |
| Starts the task runner. | |
| virtual bool | isStarted () const |
| void | addTask (CompositeTask *task) |
| Adds a new CompositeTask to the Set of Tasks that this class manages. | |
| void | removeTask (CompositeTask *task) |
| Removes a CompositeTask that was added previously. | |
| virtual void | shutdown (long long timeout) |
| Shutdown after a timeout, does not guarantee that the task's iterate method has completed and the thread halted. | |
| virtual void | shutdown () |
| Shutdown once the task has finished and the TaskRunner's thread has exited. | |
| virtual void | wakeup () |
| Signal the TaskRunner to wakeup and execute another iteration cycle on the task, the Task instance will be run until its iterate method has returned false indicating it is done. | |
| Public Member Functions inherited from activemq::threads::TaskRunner | |
| virtual | ~TaskRunner () |
| Public Member Functions inherited from activemq::threads::Task | |
| virtual | ~Task () |
| Public Member Functions inherited from decaf::lang::Runnable | |
| virtual | ~Runnable () |
Protected Member Functions | |
| virtual void | run () |
| Run method - called by the Thread class in the context of the thread. | |
| virtual bool | iterate () |
| Perform one iteration of work, returns true if the task needs to run again to complete or false to indicate that the task is now complete. | |
A Task Runner that can contain one or more CompositeTasks that are each checked for pending work and run if any is present in the order that the tasks were added.
| activemq::threads::CompositeTaskRunner::CompositeTaskRunner | ( | ) |
|
virtual |
| void activemq::threads::CompositeTaskRunner::addTask | ( | CompositeTask * | task | ) |
Adds a new CompositeTask to the Set of Tasks that this class manages.
| task | - Pointer to a CompositeTask instance. |
|
virtual |
Implements activemq::threads::TaskRunner.
|
protectedvirtual |
Perform one iteration of work, returns true if the task needs to run again to complete or false to indicate that the task is now complete.
Implements activemq::threads::Task.
| void activemq::threads::CompositeTaskRunner::removeTask | ( | CompositeTask * | task | ) |
Removes a CompositeTask that was added previously.
| task | - Pointer to a CompositeTask instance. |
|
protectedvirtual |
Run method - called by the Thread class in the context of the thread.
Implements decaf::lang::Runnable.
|
virtual |
Shutdown once the task has finished and the TaskRunner's thread has exited.
Implements activemq::threads::TaskRunner.
|
virtual |
Shutdown after a timeout, does not guarantee that the task's iterate method has completed and the thread halted.
| timeout | - Time in Milliseconds to wait for the task to stop. |
Implements activemq::threads::TaskRunner.
|
virtual |
Starts the task runner.
Prior to call this method tasks can be added to a Runner, but no executions will occur. The start method will create the background Thread(s) which do the work for this task runner.
Implements activemq::threads::TaskRunner.
|
virtual |
Signal the TaskRunner to wakeup and execute another iteration cycle on the task, the Task instance will be run until its iterate method has returned false indicating it is done.
Implements activemq::threads::TaskRunner.