- Sort Score
- Result 10 results
- Languages All
Results 1 - 7 of 7 for updateAndGet (0.15 sec)
-
guava-tests/test/com/google/common/util/concurrent/AtomicDoubleTest.java
assertBitEquals(x - y, a.get()); } } } /** updateAndGet with sum stores sum of given value to current, and returns current value */ public void testUpdateAndGetWithSum() { for (double x : VALUES) { for (double y : VALUES) { AtomicDouble a = new AtomicDouble(x); double z = a.updateAndGet(value -> value + y); assertBitEquals(x + y, z);
Registered: Wed Jun 12 16:38:11 UTC 2024 - Last Modified: Wed Feb 09 22:57:07 UTC 2022 - 10.2K bytes - Viewed (0) -
subprojects/core/src/main/java/org/gradle/internal/id/ConfigurationCacheableIdFactory.java
* * @throws IllegalStateException if an id has already been loaded. */ public long createId() { long newId = sequence.updateAndGet(it -> it == USED_ASSIGNED_ID_MARKER ? it : it + 1); if (newId == USED_ASSIGNED_ID_MARKER) { throw new IllegalStateException("Cannot create a new id after one has been loaded"); }
Registered: Wed Jun 12 18:38:38 UTC 2024 - Last Modified: Tue Mar 12 02:21:10 UTC 2024 - 2.2K bytes - Viewed (0) -
guava-tests/test/com/google/common/util/concurrent/AtomicDoubleArrayTest.java
} } } } /** updateAndGet adds given value to current, and returns current value */ public void testUpdateAndGetWithSum() { AtomicDoubleArray aa = new AtomicDoubleArray(SIZE); for (int i : new int[] {0, SIZE - 1}) { for (double x : VALUES) { for (double y : VALUES) { aa.set(i, x); double z = aa.updateAndGet(i, value -> value + y);
Registered: Wed Jun 12 16:38:11 UTC 2024 - Last Modified: Tue Feb 13 14:28:25 UTC 2024 - 14.5K bytes - Viewed (0) -
guava/src/com/google/common/util/concurrent/AtomicDouble.java
* @since 31.1 */ @CanIgnoreReturnValue public final double accumulateAndGet(double x, DoubleBinaryOperator accumulatorFunction) { checkNotNull(accumulatorFunction); return updateAndGet(oldValue -> accumulatorFunction.applyAsDouble(oldValue, x)); } /** * Atomically updates the current value with the results of applying the given function. *
Registered: Wed Jun 12 16:38:11 UTC 2024 - Last Modified: Tue Apr 04 09:45:04 UTC 2023 - 9.5K bytes - Viewed (0) -
platforms/core-execution/file-watching/src/main/java/org/gradle/internal/watch/vfs/impl/FileWatchingFilter.java
if (buildRunning) { // TODO Should the loop go on the outside to make updates smaller and less likely to collide, and also cheaper to re-run? locationsWrittenByCurrentBuild.updateAndGet(currentValue -> { FileHierarchySet newValue = currentValue; for (String location : locations) { newValue = newValue.plus(location); }
Registered: Wed Jun 12 18:38:38 UTC 2024 - Last Modified: Wed Nov 22 09:41:33 UTC 2023 - 3K bytes - Viewed (0) -
guava/src/com/google/common/util/concurrent/AtomicDoubleArray.java
* @since 31.1 */ @CanIgnoreReturnValue public final double accumulateAndGet(int i, double x, DoubleBinaryOperator accumulatorFunction) { checkNotNull(accumulatorFunction); return updateAndGet(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 value. *
Registered: Wed Jun 12 16:38:11 UTC 2024 - Last Modified: Tue Apr 04 09:45:04 UTC 2023 - 10.2K bytes - Viewed (0) -
guava/src/com/google/common/util/concurrent/AtomicLongMap.java
* returns the new value. If there is not currently a value associated with {@code key}, the * function is applied to {@code 0L}. * * @since 21.0 */ @CanIgnoreReturnValue public long updateAndGet(K key, LongUnaryOperator updaterFunction) { checkNotNull(updaterFunction); Long result = map.compute( key,
Registered: Wed Jun 12 16:38:11 UTC 2024 - Last Modified: Mon Apr 01 16:15:01 UTC 2024 - 11.8K bytes - Viewed (0)