41 #include "../Logger.hpp" 48 if ( this->owner_act && this->owner_act->
isRunning() ) {
51 <<
"Activity still running, but RunnableInterface destroyed! Stop the task" 52 " before deleting this object. Crash may be imminent."<<endlog();
54 if ( this->owner_act )
84 return owner_act->
thread();
virtual void setActivity(ActivityInterface *task)
Set the task this interface is run in.
virtual ~RunnableInterface()
Checks if this is still in a task and if so, issues a critical warning.
virtual bool isRunning() const =0
Query if the activity is initialized and executing.
virtual os::ThreadInterface * getThread() const
Get the thread this object is run in.
virtual void step()=0
The method that will be (periodically) executed when this object is run in an Activity.
A thread which is being run.
virtual bool hasWork()
This method is for 'intelligent' activity implementations that wish to see if it is required to call ...
Interface to start/stop and query a Activity.
virtual os::ThreadInterface * thread()=0
Returns a pointer to the thread which will run this activity.
Notify the Logger in which 'module' the message occured.
virtual void loop()
The method that will be executed once when this class is run in a non periodic Activity.
virtual bool breakLoop()
This method is called by the framework to break out of the loop() method.
Contains TaskContext, Activity, OperationCaller, Operation, Property, InputPort, OutputPort, Attribute.
RunnableInterface()
Create a runnable object.
void disableRun(RunnableInterface *caller)
This method is only meant for RunnableInterface (ie runner) in order to inform the ActivityInterface ...
virtual void work(WorkReason reason)
Identical to step() but gives a reason why the function was called.