Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 2 of 2 for getAndUpdate (0.26 sec)

  1. guava/src/com/google/common/util/concurrent/AtomicLongMap.java

        return getAndUpdate(key, oldValue -> accumulatorFunction.applyAsLong(oldValue, x));
      }
    
      /**
       * Associates {@code newValue} with {@code key} in this map, and returns the value previously
       * associated with {@code key}, or zero if there was no such value.
       */
      @CanIgnoreReturnValue
      public long put(K key, long newValue) {
        return getAndUpdate(key, x -> newValue);
      }
    
      /**
    Registered: Fri Dec 26 12:43:10 UTC 2025
    - Last Modified: Fri Oct 10 23:13:45 UTC 2025
    - 11.7K bytes
    - Viewed (0)
  2. guava/src/com/google/common/util/concurrent/AtomicDoubleArray.java

       * @since 31.1
       */
      @CanIgnoreReturnValue
      public final double getAndAccumulate(int i, double x, DoubleBinaryOperator accumulatorFunction) {
        checkNotNull(accumulatorFunction);
        return getAndUpdate(i, oldValue -> accumulatorFunction.applyAsDouble(oldValue, x));
      }
    
      /**
       * Atomically updates the element at index {@code i} with the results of applying the given
       * function to the current and given values.
    Registered: Fri Dec 26 12:43:10 UTC 2025
    - Last Modified: Mon Mar 17 20:26:29 UTC 2025
    - 10.2K bytes
    - Viewed (0)
Back to top