Method Count
Count<TInput, TIntermediate>(PipelineDefinition<TInput, TIntermediate>)
Appends a $count stage to the pipeline.
public static PipelineDefinition<TInput, AggregateCountResult> Count<TInput, TIntermediate>(this PipelineDefinition<TInput, TIntermediate> pipeline)
Parameters
pipelinePipelineDefinition<TInput, TIntermediate>The pipeline.
Returns
- PipelineDefinition<TInput, AggregateCountResult>
A new pipeline with an additional stage.
Type Parameters
TInputThe type of the input documents.
TIntermediateThe type of the intermediate documents.