Embedded Multicore Building Blocks V1.0.0
|
Contains attributes of a Task. More...
#include <task_attributes.h>
Public Member Functions | |
TaskAttributes () | |
Constructs a TaskAttributes object. More... | |
TaskAttributes & | SetDetached (bool state) |
Sets the detached property of a Task. More... | |
TaskAttributes & | SetPriority (mtapi_uint_t priority) |
Sets the priority of a Task. More... | |
TaskAttributes & | SetAffinity (mtapi_affinity_t affinity) |
Sets the affinity of a Task. More... | |
TaskAttributes & | SetPolicy (ExecutionPolicy const &policy) |
Sets the ExecutionPolicy of a Task. More... | |
TaskAttributes & | SetInstances (mtapi_uint_t instances) |
Sets the number of instances in a Task. More... | |
mtapi_task_attributes_t const & | GetInternal () const |
Returns the internal representation of this object. More... | |
Contains attributes of a Task.
embb::mtapi::TaskAttributes::TaskAttributes | ( | ) |
Constructs a TaskAttributes object.
TaskAttributes& embb::mtapi::TaskAttributes::SetDetached | ( | bool | state | ) |
TaskAttributes& embb::mtapi::TaskAttributes::SetPriority | ( | mtapi_uint_t | priority | ) |
Sets the priority of a Task.
The priority influences the order in which tasks are chosen for execution.
priority | The priority to set. |
TaskAttributes& embb::mtapi::TaskAttributes::SetAffinity | ( | mtapi_affinity_t | affinity | ) |
TaskAttributes& embb::mtapi::TaskAttributes::SetPolicy | ( | ExecutionPolicy const & | policy | ) |
Sets the ExecutionPolicy of a Task.
The ExecutionPolicy determines the affinity and priority of a Task.
policy | The ExecutionPolicy to set. |
TaskAttributes& embb::mtapi::TaskAttributes::SetInstances | ( | mtapi_uint_t | instances | ) |
Sets the number of instances in a Task.
The Task will be launched instances
times. In the action function, the number of instances and the current instance can be queried from the TaskContext.
instances | Number of instances to set. |
mtapi_task_attributes_t const& embb::mtapi::TaskAttributes::GetInternal | ( | ) | const |
Returns the internal representation of this object.
Allows for interoperability with the C interface.