tf::Pipeflow class | Taskflow QuickStart

# tf::Pipeflow class
#include <taskflow/algorithm/pipeline.hpp>

class to create a pipeflow object used by the pipe callable

Pipeflow represents a scheduling token in the pipeline scheduling framework. A pipeflow is created by the pipeline scheduler at runtime to pass to the pipe callable. Users can query the present statistics of that scheduling token, including the line identifier, pipe identifier, and token identifier, and build their application algorithms based on these statistics. At the first stage, users can explicitly call the stop method to stop the pipeline scheduler.

    tf::Pipe{tf::PipeType::SERIAL, [](tf::Pipeflow& pf){
      std::cout << "token id=" << pf.token()
                << " at line=" << pf.line()
                << " at pipe=" << pf.pipe()
                << '\n';
    }};

Pipeflow can only be created privately by the tf::Pipeline and be used through the pipe callable.

## Constructors, destructors, conversion operators

Pipeflow() defaulted
  default constructor

## Public functions

auto line() const -> size_t
  queries the line identifier of the present token
auto pipe() const -> size_t
  queries the pipe identifier of the present token
auto token() const -> size_t
  queries the token identifier
void stop()
  stops the pipeline scheduling
auto num_deferrals() const -> size_t
  queries the number of deferrals
void defer(size_t token)
  pushes token in _dependents

## Function documentation

### void tf::Pipeflow::stop()

stops the pipeline scheduling

Only the first pipe can call this method to stop the pipeline. Calling stop from other pipes will throw exception.

### void tf::Pipeflow::defer(size_t token)

pushes token in _dependents

Only the first pipe can call this method to defer the current scheduling token to the given token.

Tab / T to search, Esc to close
…

Search for symbols, directories, files, pages or modules. You can omit any prefix from the symbol or file path; adding a `:` or `/` suffix lists all members of given symbol or directory.

Use ↓ / ↑ to navigate through the list, Enter to go. Tab autocompletes common prefix, you can copy a link to the result using ⌘ L while ⌘ M produces a Markdown link.

Sorry, nothing was found.