Interface Aggregator.Accumulator
- Enclosing interface:
Aggregator
public static interface Aggregator.Accumulator
Can accumulate multiple data items of a consistent type and
yield an aggregate value corresponding to the set.
- Since:
- 16 Nov 2022
- Author:
- Mark Taylor
-
Method Summary
Modifier and TypeMethodDescriptionvoidadd(Aggregator.Accumulator other) Combines the content of another compatible accumulator with the content of this one.Returns the aggregated value for the values accumulated so far.voidSubmits a value for accumulation.
-
Method Details
-
submit
-
getResult
Object getResult()Returns the aggregated value for the values accumulated so far.- Returns:
- accumulated result
-
add
Combines the content of another compatible accumulator with the content of this one. The effect is as if all the data that have been accumulated intootherwere accumulated additionally into this one.- Parameters:
other- other compatible accumulator
-