aggregate
Aggregates documents according to the specified aggregation pipeline. If the pipeline ends with a $out stage, the returned iterable will be a query of the collection that the aggregation was written to. Note that in this case the pipeline will be executed even if the iterable is never iterated.
Return
an iterable containing the result of the aggregation operation
Parameters
the aggregate pipeline
Aggregates documents according to the specified aggregation pipeline. If the pipeline ends with a $out stage, the returned iterable will be a query of the collection that the aggregation was written to. Note that in this case the pipeline will be executed even if the iterable is never iterated.
Return
an iterable containing the result of the aggregation operation
Parameters
the aggregate pipeline
the class to decode each document into
Aggregates documents according to the specified aggregation pipeline. If the pipeline ends with a $out stage, the returned iterable will be a query of the collection that the aggregation was written to. Note that in this case the pipeline will be executed even if the iterable is never iterated.
Return
an iterable containing the result of the aggregation operation
Since
3.6
Parameters
the client session with which to associate this operation
the aggregate pipeline
Aggregates documents according to the specified aggregation pipeline. If the pipeline ends with a $out stage, the returned iterable will be a query of the collection that the aggregation was written to. Note that in this case the pipeline will be executed even if the iterable is never iterated.
Return
an iterable containing the result of the aggregation operation
Since
3.6
Parameters
the client session with which to associate this operation
the aggregate pipeline
the class to decode each document into