mongo4cats.operations.Accumulator
See theAccumulator companion trait
object Accumulator
Attributes
- Companion
- trait
- Graph
-
- Supertypes
-
trait AsJavaConvertersclass Objecttrait Matchableclass Any
- Self type
-
Accumulator.type
Members list
Value members
Concrete methods
def apply(fieldName: String, initFunction: String, accumulateFunction: String, mergeFunction: String, initArgs: List[String], accumulateArgs: List[String], finalizeFunction: Option[String], lang: String): Accumulator
Creates an $accumulator pipeline stage
Creates an $accumulator pipeline stage
Value parameters
- accumulateArgs
-
additional accumulate function’s arguments. The first argument to the function is ‘state’.
- accumulateFunction
-
a function used to accumulate documents
- fieldName
-
the field name
- finalizeFunction
-
a function used to finalize the state and return the result
- initArgs
-
init function’s arguments
- initFunction
-
a function used to initialize the state
- lang
-
a language specifier
- mergeFunction
-
a function used to merge two internal states, e.g. accumulated on different shards or threads. It returns the resulting state of the accumulator.
Attributes
- Returns
-
the $accumulator pipeline stage https://docs.mongodb.com/manual/reference/operator/aggregation/accumulator/
- Since
-
4.1
Inherited methods
Attributes
- Inherited from:
- AsJavaConverters
Attributes
- Inherited from:
- AsJavaConverters
Attributes
- Inherited from:
- AsJavaConverters
Attributes
- Inherited from:
- AsJavaConverters
Attributes
- Inherited from:
- AsJavaConverters
Attributes
- Inherited from:
- AsJavaConverters
Attributes
- Inherited from:
- AsJavaConverters
Attributes
- Inherited from:
- AsJavaConverters
Attributes
- Inherited from:
- AsJavaConverters
Attributes
- Inherited from:
- AsJavaConverters
Attributes
- Inherited from:
- AsJavaConverters
Attributes
- Inherited from:
- AsJavaConverters
Attributes
- Inherited from:
- AsJavaConverters
In this article