agency::sequenced_execution_policy Class Reference

Encapsulates requirements for creating groups of sequenced execution agents. More...

Inheritance diagram for agency::sequenced_execution_policy:
agency::basic_execution_policy< sequenced_agent, sequenced_executor, sequenced_execution_policy >

Additional Inherited Members

- Public Types inherited from agency::basic_execution_policy< sequenced_agent, sequenced_executor, sequenced_execution_policy >
using execution_agent_type = sequenced_agent
 The type of execution agent associated with this basic_execution_policy.
 
using executor_type = sequenced_executor
 The type of executor associated with this basic_execution_policy.
 
using param_type = typename execution_agent_traits< execution_agent_type >::param_type
 The type of this execution policy's parameterization.
 
- Public Member Functions inherited from agency::basic_execution_policy< sequenced_agent, sequenced_executor, sequenced_execution_policy >
 basic_execution_policy ()=default
 The default constructor default constructs this execution policy's associated executor and parameterization.
 
 basic_execution_policy (const param_type &param, const executor_type &executor=executor_type{})
 This constructor constructs a new basic_execution_policy given a parameterization and executor. More...
 
const param_typeparam () const
 Returns this execution policy's parameterization.
 
executor_typeexecutor () const
 Returns this execution policy's associated executor.
 
auto on (const OtherExecutor &exec) const -> decltype(replace_executor(*this, exec))
 Replaces this execution policy's executor with another. More...
 
see_below operator() (Arg1 &&arg1, Args &&...args) const
 Reparameterizes this execution policy. More...
 

Detailed Description

When used as a control structure parameter, sequenced_execution_policy requires the creation of a group of execution agents which execute in sequence. Agents in such a group execute on the thread which invokes the control structure. However, if the executor of a sequenced_execution_policy is replaced with another sequenced executor of a different type, the agents may execute in sequence on another thread or threads, depending on the type of that executor.

The order in which sequenced execution agents execute is given by the lexicographical order of their indices.

The type of execution agent sequenced_execution_policy induces is sequenced_agent, and the type of its associated executor is sequenced_executor.

See also
Execution Policies
basic_execution_policy
seq
sequenced_agent
sequenced_executor
sequenced_execution_tag