public interface AccumulableParam<R,T>
extends java.io.Serializable
Accumulable
s of a specific type.
Modifier and Type | Method and Description |
---|---|
R |
addAccumulator(R r,
T t)
Add additional data to the accumulator value.
|
R |
addInPlace(R r1,
R r2)
Merge two accumulated values together.
|
R |
zero(R initialValue)
Return the "zero" (identity) value for an accumulator type, given its initial value.
|
R addAccumulator(R r, T t)
r
for efficiency (to avoid allocating objects).
r
- the current value of the accumulatort
- the data to be added to the accumulatorR addInPlace(R r1, R r2)
r1
- one set of accumulated datar2
- another set of accumulated data