Skip to content

PipelineBuilder<TBaseNode>.AddParallelStage Method ​

Overloads ​

NameDescription
AddParallelStage(Action<ParallelPipelineStageBuilder<TBaseNode>>)Adds a stage to the pipeline that runs Processors in parallel. Its name will be the number of the stage.
AddParallelStage<TProcessor>()Adds a parallel stage with a single processor of type TProcessor to the pipeline. The stage will be named after its position in the pipeline.
AddParallelStage<TProcessor>(String)Adds a parallel stage with the specified name and a single processor of type TProcessor to the pipeline.
AddParallelStage(IEnumerable<Processor<TBaseNode>>)Adds a stage to the pipeline with the specified Processors to be run in parallel. Its name will be the number of the stage.
AddParallelStage(String, IEnumerable<Processor<TBaseNode>>)Adds a stage with the specified name to the pipeline with the specified Processors to be run in parallel. Its name will be the number of the stage.
AddParallelStage(Int32, IEnumerable<Processor<TBaseNode>>)Adds a stage to the pipeline with the specified Processors to be run in parallel with the specified maximum degree of parallelism. Its name will be the number of the stage.
AddParallelStage(String, Int32, IEnumerable<Processor<TBaseNode>>)Adds a stage with the specified name to the pipeline with the specified Processors to be run in parallel with the specified maximum degree of parallelism.

AddParallelStage(Action<ParallelPipelineStageBuilder<TBaseNode>>) ​

Adds a stage to the pipeline that runs Processors in parallel. Its name will be the number of the stage.

c#
public PipelineBuilder<TBaseNode> AddParallelStage(Action<ParallelPipelineStageBuilder<TBaseNode>> build);

View source

Parameters ​

NameTypeDescription
buildAction<ParallelPipelineStageBuilder<TBaseNode>>An action to perform on a ParallelPipelineStageBuilder<TBaseNode> to build the pipeline.

Returns ​

PipelineBuilder<TBaseNode>

The fluent builder.

AddParallelStage<TProcessor>() ​

Adds a parallel stage with a single processor of type TProcessor to the pipeline. The stage will be named after its position in the pipeline.

c#
public PipelineBuilder<TBaseNode> AddParallelStage<TProcessor>()
   where TProcessor : Processor<TBaseNode>, new();

View source

Type Parameters ​

NameDescription
TProcessorThe type of the processor.

Returns ​

PipelineBuilder<TBaseNode>

The fluent builder.

AddParallelStage<TProcessor>(String) ​

Adds a parallel stage with the specified name and a single processor of type TProcessor to the pipeline.

c#
public PipelineBuilder<TBaseNode> AddParallelStage<TProcessor>(string name)
   where TProcessor : Processor<TBaseNode>, new();

View source

Type Parameters ​

NameDescription
TProcessorThe type of the processor.

Parameters ​

NameTypeDescription
nameStringThe name of the stage.

Returns ​

PipelineBuilder<TBaseNode>

The fluent builder.

AddParallelStage(IEnumerable<Processor<TBaseNode>>) ​

Adds a stage to the pipeline with the specified Processors to be run in parallel. Its name will be the number of the stage.

c#
public PipelineBuilder<TBaseNode> AddParallelStage(params IEnumerable<Processor<TBaseNode>> processors);

View source

Parameters ​

NameTypeDescription
processorsIEnumerable<Processor<TBaseNode>>The processors to add.

Returns ​

PipelineBuilder<TBaseNode>

The fluent builder.

AddParallelStage(String, IEnumerable<Processor<TBaseNode>>) ​

Adds a stage with the specified name to the pipeline with the specified Processors to be run in parallel. Its name will be the number of the stage.

c#
public PipelineBuilder<TBaseNode> AddParallelStage(string name, params IEnumerable<Processor<TBaseNode>> processors);

View source

Parameters ​

NameTypeDescription
nameStringThe name of the stage.
processorsIEnumerable<Processor<TBaseNode>>The processors to add.

Returns ​

PipelineBuilder<TBaseNode>

The fluent builder.

AddParallelStage(Int32, IEnumerable<Processor<TBaseNode>>) ​

Adds a stage to the pipeline with the specified Processors to be run in parallel with the specified maximum degree of parallelism. Its name will be the number of the stage.

c#
public PipelineBuilder<TBaseNode> AddParallelStage(int maxDegreeOfParallelism, params IEnumerable<Processor<TBaseNode>> processors);

View source

Parameters ​

NameTypeDescription
maxDegreeOfParallelismInt32The maximum degree of parallelism. If set to one, then the stage will proceed in serial. If greater than one, then one thread will be used to walk the tree and the other threads will be used to process the nodes.
processorsIEnumerable<Processor<TBaseNode>>The processors to add.

Returns ​

PipelineBuilder<TBaseNode>

The fluent builder.

AddParallelStage(String, Int32, IEnumerable<Processor<TBaseNode>>) ​

Adds a stage with the specified name to the pipeline with the specified Processors to be run in parallel with the specified maximum degree of parallelism.

c#
public PipelineBuilder<TBaseNode> AddParallelStage(string name, int maxDegreeOfParallelism, params IEnumerable<Processor<TBaseNode>> processors);

View source

Parameters ​

NameTypeDescription
nameStringThe name of the stage.
maxDegreeOfParallelismInt32The maximum degree of parallelism. If set to one, then the stage will proceed in serial. If greater than one, then one thread will be used to walk the tree and the other threads will be used to process the nodes.
processorsIEnumerable<Processor<TBaseNode>>The processors to add.

Returns ​

PipelineBuilder<TBaseNode>

The fluent builder.