Package dev.morphia.aggregation
Interface Aggregation<T>
- Type Parameters:
T- The initial type of the aggregation. Used for collection name resolution.
- All Superinterfaces:
AutoCloseable,Iterable<T>
- Since:
- 2.0
-
Method Summary
Modifier and TypeMethodDescriptioniterator()Appends the stages to this aggregation's pipeline.default Aggregation<T>Appends the stages to this aggregation's pipeline.toList()Executes the aggregation pipeline and collects all results into a list.Methods inherited from interface java.lang.AutoCloseable
closeMethods inherited from interface java.lang.Iterable
forEach, spliterator
-
Method Details
-
pipeline
Appends the stages to this aggregation's pipeline.- Parameters:
stages- the stages to add- Returns:
- this
- Since:
- 3.0
-
pipeline
Appends the stages to this aggregation's pipeline.- Parameters:
stages- the stages to add- Returns:
- this
- Since:
- 3.0
-
iterator
MorphiaCursor<T> iterator() -
toList
Executes the aggregation pipeline and collects all results into a list.- Returns:
- a list containing all results of the aggregation
-