Method UnionWith
UnionWith<TInput, TWith>(IMongoCollection<TWith>, PipelineDefinition<TWith, TInput>)
Creates a $unionWith stage.
public static PipelineStageDefinition<TInput, TInput> UnionWith<TInput, TWith>(IMongoCollection<TWith> withCollection, PipelineDefinition<TWith, TInput> withPipeline = null)
Parameters
withCollection
IMongoCollection<TWith>The with collection.
withPipeline
PipelineDefinition<TWith, TInput>The with pipeline.
Returns
- PipelineStageDefinition<TInput, TInput>
The stage.
Type Parameters
TInput
The type of the input documents.
TWith
The type of the with collection documents.