Base module
Runnable
Abstract interface for classes that can be run and cancelled.
Runnable
#include <icy/interface.h>class RunnableDefined in src/base/include/icy/interface.h:75
Subclassed by:
RunnableQueue< IPacket >,RunnableQueue< PacketT >,PlanarAudioPacket >,RunnableQueue< VisionFramePacket >,AsyncDiagnostic,AsyncLogWriter,RunnableQueue< T >,Task,TaskRunner,MediaCapture,InstallTask
Abstract interface for classes that can be run and cancelled.
List of all members
| Name | Kind | Owner |
|---|---|---|
Runnable | function | Declared here |
~Runnable | function | Declared here |
run | function | Declared here |
cancel | function | Declared here |
cancelled | function | Declared here |
exit | variable | Declared here |
Public Methods
| Return | Name | Description |
|---|---|---|
Runnable inline | ||
void | run virtual | The run method will be called by the asynchronous context. |
void | cancel virtual inline | Cancel the current task. The run() method should return ASAP. |
bool | cancelled virtual const inline | Returns true when the task has been cancelled. |
Runnable
inline
inline Runnable()Defined in src/base/include/icy/interface.h:78
run
virtual
virtual void run()Defined in src/base/include/icy/interface.h:86
The run method will be called by the asynchronous context.
Reimplemented by
cancel
virtual inline
virtual inline void cancel(bool flag = true)Defined in src/base/include/icy/interface.h:90
Cancel the current task. The run() method should return ASAP.
Reimplemented by
cancelled
virtual const inline
virtual inline bool cancelled() constDefined in src/base/include/icy/interface.h:96
Returns true when the task has been cancelled.
Reimplemented by
Protected Attributes
| Return | Name | Description |
|---|---|---|
std::atomic< bool > | exit |
exit
std::atomic< bool > exit