Interface ArithmeticAccumulator<T,R>

Type Parameters:
T - type of the element in the Arithmetic
R - type of the resulting element

public interface ArithmeticAccumulator<T,R>
Defines the contract for Arithmetic Accumulator.
  • Method Details

    • newInstance

      ArithmeticAccumulator<T,R> newInstance()
      Creates new Instance.
      Returns:
      the result of newInstance
    • accumulate

      void accumulate(T value)
      Performs accumulate.
      Parameters:
      value - the value value
    • combine

      Performs combine.
      Parameters:
      other - the other value
      Returns:
      the result of combine
    • result

      R result()
      Performs result.
      Returns:
      the result of result