com.hazelcast.jet.accumulator

## Class DoubleAccumulator

- java.lang.Object
- - com.hazelcast.jet.accumulator.DoubleAccumulator

-     public class DoubleAccumulator
      extends Object

  Accumulator of a `double` value.
  Since:
    3.0

- - ### Constructor Summary

    Constructors
    Constructor and Description
    `DoubleAccumulator()` Creates a new instance with `value == 0`.
    `DoubleAccumulator(double value)` Creates a new instance with the specified value.

  - ### Method Summary

    All Methods Instance Methods Concrete Methods
    Modifier and Type | Method and Description
    --- | ---
    `DoubleAccumulator` | `accumulate(double v)` Adds the value to this objects' value.
    `DoubleAccumulator` | `combine(DoubleAccumulator that)` Adds the value of the supplied accumulator to this one.
    `DoubleAccumulator` | `deduct(DoubleAccumulator that)` Subtracts the value of the supplied accumulator from this one.
    `boolean` | `equals(Object o)`
    `double` | `export()` Returns the current value.
    `int` | `hashCode()`
    `DoubleAccumulator` | `set(double value)` Sets the value as given.
    `String` | `toString()`

    - ### Methods inherited from class java.lang.Object

      `clone, finalize, getClass, notify, notifyAll, wait, wait, wait`

- - ### Constructor Detail

    - #### DoubleAccumulator

          public DoubleAccumulator()

      Creates a new instance with `value == 0`.

    - #### DoubleAccumulator

          public DoubleAccumulator(double value)

      Creates a new instance with the specified value.

  - ### Method Detail

    - #### set

          public DoubleAccumulator set(double value)

      Sets the value as given.

    - #### accumulate

          public DoubleAccumulator accumulate(double v)

      Adds the value to this objects' value.

    - #### combine

          public DoubleAccumulator combine(DoubleAccumulator that)

      Adds the value of the supplied accumulator to this one.

    - #### deduct

          public DoubleAccumulator deduct(DoubleAccumulator that)

      Subtracts the value of the supplied accumulator from this one.

    - #### export

          public double export()

      Returns the current value.

    - #### equals

          public boolean equals(Object o)

      Overrides:
        `equals` in class `Object`

    - #### hashCode

          public int hashCode()

      Overrides:
        `hashCode` in class `Object`

    - #### toString

          public String toString()

      Overrides:
        `toString` in class `Object`

Copyright © 2019. All rights reserved.