Method Unwind
Unwind<TResult>(IAggregateFluent<TResult>, FieldDefinition<TResult>)
Appends an unwind stage to the pipeline.
public static IAggregateFluent<BsonDocument> Unwind<TResult>(this IAggregateFluent<TResult> aggregate, FieldDefinition<TResult> field)
Parameters
aggregateIAggregateFluent<TResult>The aggregate.
fieldFieldDefinition<TResult>The field to unwind.
Returns
- IAggregateFluent<BsonDocument>
The fluent aggregate interface.
Type Parameters
TResultThe type of the result.
Unwind<TResult>(IAggregateFluent<TResult>, Expression<Func<TResult, object>>)
Appends an unwind stage to the pipeline.
public static IAggregateFluent<BsonDocument> Unwind<TResult>(this IAggregateFluent<TResult> aggregate, Expression<Func<TResult, object>> field)
Parameters
aggregateIAggregateFluent<TResult>The aggregate.
fieldExpression<Func<TResult, object>>The field to unwind.
Returns
- IAggregateFluent<BsonDocument>
The fluent aggregate interface.
Type Parameters
TResultThe type of the result.
Unwind<TResult, TNewResult>(IAggregateFluent<TResult>, Expression<Func<TResult, object>>, IBsonSerializer<TNewResult>)
Appends an unwind stage to the pipeline.
[Obsolete("Use the Unwind overload which takes an options parameter.")]
public static IAggregateFluent<TNewResult> Unwind<TResult, TNewResult>(this IAggregateFluent<TResult> aggregate, Expression<Func<TResult, object>> field, IBsonSerializer<TNewResult> newResultSerializer)
Parameters
aggregateIAggregateFluent<TResult>The aggregate.
fieldExpression<Func<TResult, object>>The field to unwind.
newResultSerializerIBsonSerializer<TNewResult>The new result serializer.
Returns
- IAggregateFluent<TNewResult>
The fluent aggregate interface.
Type Parameters
TResultThe type of the result.
TNewResultThe type of the new result.
Unwind<TResult, TNewResult>(IAggregateFluent<TResult>, Expression<Func<TResult, object>>, AggregateUnwindOptions<TNewResult>)
Appends an unwind stage to the pipeline.
public static IAggregateFluent<TNewResult> Unwind<TResult, TNewResult>(this IAggregateFluent<TResult> aggregate, Expression<Func<TResult, object>> field, AggregateUnwindOptions<TNewResult> options = null)
Parameters
aggregateIAggregateFluent<TResult>The aggregate.
fieldExpression<Func<TResult, object>>The field to unwind.
optionsAggregateUnwindOptions<TNewResult>The options.
Returns
- IAggregateFluent<TNewResult>
The fluent aggregate interface.
Type Parameters
TResultThe type of the result.
TNewResultThe type of the new result.