Method BucketAuto
BucketAuto<TInput, TValue>(AggregateExpressionDefinition<TInput, TValue>, int, AggregateBucketAutoOptions)
Creates a $bucketAuto stage.
public static PipelineStageDefinition<TInput, AggregateBucketAutoResult<TValue>> BucketAuto<TInput, TValue>(AggregateExpressionDefinition<TInput, TValue> groupBy, int buckets, AggregateBucketAutoOptions options = null)
Parameters
groupByAggregateExpressionDefinition<TInput, TValue>The group by expression.
bucketsintThe number of buckets.
optionsAggregateBucketAutoOptionsThe options.
Returns
- PipelineStageDefinition<TInput, AggregateBucketAutoResult<TValue>>
The stage.
Type Parameters
TInputThe type of the input documents.
TValueThe type of the values.
BucketAuto<TInput, TValue, TOutput>(AggregateExpressionDefinition<TInput, TValue>, int, ProjectionDefinition<TInput, TOutput>, AggregateBucketAutoOptions)
Creates a $bucketAuto stage.
public static PipelineStageDefinition<TInput, TOutput> BucketAuto<TInput, TValue, TOutput>(AggregateExpressionDefinition<TInput, TValue> groupBy, int buckets, ProjectionDefinition<TInput, TOutput> output, AggregateBucketAutoOptions options = null)
Parameters
groupByAggregateExpressionDefinition<TInput, TValue>The group by expression.
bucketsintThe number of buckets.
outputProjectionDefinition<TInput, TOutput>The output projection.
optionsAggregateBucketAutoOptionsThe options.
Returns
- PipelineStageDefinition<TInput, TOutput>
The stage.
Type Parameters
TInputThe type of the input documents.
TValueThe type of the values.
TOutputThe type of the output documents.
BucketAuto<TInput, TValue>(Expression<Func<TInput, TValue>>, int, AggregateBucketAutoOptions)
Creates a $bucketAuto stage.
public static PipelineStageDefinition<TInput, AggregateBucketAutoResult<TValue>> BucketAuto<TInput, TValue>(Expression<Func<TInput, TValue>> groupBy, int buckets, AggregateBucketAutoOptions options = null)
Parameters
groupByExpression<Func<TInput, TValue>>The group by expression.
bucketsintThe number of buckets.
optionsAggregateBucketAutoOptionsThe options (optional).
Returns
- PipelineStageDefinition<TInput, AggregateBucketAutoResult<TValue>>
The stage.
Type Parameters
TInputThe type of the input documents.
TValueThe type of the value.
BucketAuto<TInput, TValue, TOutput>(Expression<Func<TInput, TValue>>, int, Expression<Func<IGrouping<AggregateBucketAutoResultId<TValue>, TInput>, TOutput>>, AggregateBucketAutoOptions)
Creates a $bucketAuto stage (this overload can only be used with LINQ3).
public static PipelineStageDefinition<TInput, TOutput> BucketAuto<TInput, TValue, TOutput>(Expression<Func<TInput, TValue>> groupBy, int buckets, Expression<Func<IGrouping<AggregateBucketAutoResultId<TValue>, TInput>, TOutput>> output, AggregateBucketAutoOptions options = null)
Parameters
groupByExpression<Func<TInput, TValue>>The group by expression.
bucketsintThe number of buckets.
outputExpression<Func<IGrouping<AggregateBucketAutoResultId<TValue>, TInput>, TOutput>>The output projection.
optionsAggregateBucketAutoOptionsThe options (optional).
Returns
- PipelineStageDefinition<TInput, TOutput>
The stage.
Type Parameters
TInputThe type of the input documents.
TValueThe type of the output documents.
TOutputThe type of the output documents.