|
Cpp-Taskflow
2.3.0
|
an immutable accessor class to a task node, mainly used in the tf::ExecutorObserver interface. More...
#include <task.hpp>
Public Member Functions | |
| TaskView ()=default | |
| constructs an empty task view | |
| TaskView (const Task &task) | |
| constructs a task view from a task | |
| TaskView (const TaskView &other) | |
| constructs the task with the copy of the other task | |
| TaskView & | operator= (const TaskView &other) |
| replaces the contents with a copy of the other task | |
| TaskView & | operator= (const Task &other) |
| replaces the contents with another task | |
| TaskView & | operator= (std::nullptr_t) |
| replaces the contents with a null pointer | |
| bool | operator== (const TaskView &) const |
| compares if two taskviews are associated with the same task | |
| bool | operator!= (const TaskView &) const |
| compares if two taskviews are associated with different tasks | |
| const std::string & | name () const |
| queries the name of the task | |
| size_t | num_successors () const |
| queries the number of successors of the task | |
| size_t | num_dependents () const |
| queries the number of predecessors of the task | |
| size_t | num_strong_dependents () const |
| queries the number of strong dependents of the task | |
| size_t | num_weak_dependents () const |
| queries the number of weak dependents of the task | |
| void | reset () |
| resets to an empty view | |
| bool | empty () const |
| queries if the task view is empty | |
| template<typename V > | |
| void | for_each_successor (V &&visitor) const |
| applies an visitor callable to each successor of the task | |
| template<typename V > | |
| void | for_each_dependent (V &&visitor) const |
| applies an visitor callable to each dependents of the task | |
Friends | |
| class | Executor |
an immutable accessor class to a task node, mainly used in the tf::ExecutorObserver interface.