20 #ifndef COIL_PERIODICTASK_H 21 #define COIL_PERIODICTASK_H 28 #include <coil/Mutex.h> 29 #include <coil/Guard.h> 30 #include <coil/Condition.h> 31 #include <coil/TimeValue.h> 32 #include <coil/TimeMeasure.h> 33 #include <coil/PeriodicTaskBase.h> 217 template <
class O,
class F>
324 virtual void sleep();
538 #endif // COIL_PERIODICTASK_H PeriodicTask()
Constructor.
bool m_deleteInDtor
Task execution function delete flag.
coil::TimeMeasure m_periodTime
Task periodic time measurement infomation.
unsigned int m_execCountMax
Task execution time measurement max count.
Structure for time statistics.
virtual void periodicMeasure(bool value)
Validate a Task period time measurement.
virtual void updateExecStat()
Update for execute state.
virtual void executionMeasure(bool value)
Validate a Task execute time measurement.
virtual int resume(void)
Resuming the suspended task.
coil::Condition< coil::Mutex > cond
virtual void activate()
Starting the task.
virtual int svc()
Thread execution for PeriodicTask.
unsigned int m_execCount
Task execution time measurement count.
virtual void periodicMeasureCount(int n)
Task period time measurement count.
coil::Guard< coil::Mutex > Guard
bool m_nowait
Thread sleep flag.
virtual void sleep()
Thread sleep.
virtual void signal()
Executing the suspended task one tick.
virtual TimeMeasure::Statistics getExecStat()
Get a result in task execute time measurement.
statistics_t m_execStat
Task execution time measurement statistics.
coil::TimeMeasure::Statistics stat
unsigned int m_periodCount
Task periodic time measurement count.
coil::TimeValue m_period
Task execution period.
bool setTask(O *obj, F fun)
Setting task execution function.
virtual bool setTask(TaskFuncBase *func, bool delete_in_dtor=true)
Setting task execution function.
unsigned int m_periodCountMax
Task periodic time measurement max count.
Structure for task suspend management.
statistics_t m_periodStat
Task periodic time measurement statistics.
virtual ~PeriodicTask()
Destructor.
bool m_execMeasure
Task execution time measurement flag.
virtual void setPeriod(double period)
Setting task execution period.
virtual void executionMeasureCount(int n)
Task execute time measurement period.
coil::TimeMeasure m_execTime
Task execution time measurement infomation.
TaskFuncBase * m_func
Task execution function.
suspend_t m_suspend
Task suspend infomation.
virtual void updatePeriodStat()
Update for period state.
virtual void finalize()
Finalizing the task.
bool m_periodMeasure
Task periodic time measurement flag.
Structure for task execution time measurement management.
virtual TimeMeasure::Statistics getPeriodStat()
Get a result in task period time measurement.
alive_t m_alive
Task alive flag.
virtual int suspend(void)
Suspending the task.
Common Object Interface Layer.