#include <ThreadContext.h>
Inheritance diagram for ot::ThreadContext:


Public Member Functions | |
| ThreadContext (int init=0) | |
| virtual | ~ThreadContext () |
| virtual void | run () |
| virtual void | runAtRate (double rate) |
| virtual void | runOnDemand () |
Protected Types | |
| enum | ActionType { POLL = 0, RATE = 1, DEMAND = 2, QUIT = 255 } |
Protected Member Functions | |
| void | thlock () |
| void | thunlock () |
| void | runDispatcher () |
Static Protected Member Functions | |
| static void | thread_func (void *data) |
Protected Attributes | |
| int | action_type |
| double | action_rate |
| bool | inloop |
| void * | thread |
| thread_mutex_type * | thread_mutex |
| mutex_type * | action_mutex |
| condition_type * | action_cond |
| mutex_type * | loopend_mutex |
| condition_type * | loopend_cond |
Friends | |
| class | ConfigurationParser |
|
|
|
|
|
a constructor method.
|
|
|
destructor method clears containers and removes any modules instantiated in the default setup, if cleanUp is st. |
|
|
This method implements the main loop and runs until it is stopped somehow. Then it calls close() on all modules. Reimplemented from ot::Context. |
|
|
This method a main loop at a fixed rate until it is stopped somehow. Then it calls close() on all modules. Reimplemented from ot::Context. |
|
|
This method implements the dispatcher, which runs one of the maint loops in the thread. |
|
|
This is a data-driven implementation of the main loop Reimplemented from ot::Context. |
|
|
enters a critical section. Use this method to protect your operations from another thread. This is not a recursive lock, do not call it several times without unlocking ! |
|
|
|
|
|
leaves a critical section. Use this method to release the protection. |
|
|
Reimplemented from ot::Context. |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1.4.6