- Sort Score
- Result 10 results
- Languages All
Results 1 - 10 of 12 for addAndGet (0.26 sec)
-
guava-tests/test/com/google/common/collect/CountTest.java
assertEquals(20, holder.get()); holder.add(1); assertEquals(21, holder.get()); } public void testAddAndGet() { Count holder = new Count(20); assertEquals(21, holder.addAndGet(1)); } public void testGetAndSet() { Count holder = new Count(10); assertEquals(10, holder.getAndSet(20)); assertEquals(20, holder.get()); } public void testSet() {
Registered: Fri Nov 01 12:43:10 UTC 2024 - Last Modified: Mon Feb 19 20:34:55 UTC 2024 - 1.5K bytes - Viewed (0) -
android/guava-tests/test/com/google/common/util/concurrent/AtomicLongMapTest.java
assertFalse(map.containsKey(key)); assertEquals(value, map.addAndGet(key, value)); assertEquals(value, map.get(key)); assertEquals(0L, map.addAndGet(key, -1 * value)); assertEquals(0L, map.get(key)); assertTrue(map.containsKey(key)); assertEquals(value, map.addAndGet(key, value)); assertEquals(value, map.get(key)); } public void testGetAndAdd() {
Registered: Fri Nov 01 12:43:10 UTC 2024 - Last Modified: Tue Feb 13 14:28:25 UTC 2024 - 17.4K bytes - Viewed (0) -
guava/src/com/google/common/util/concurrent/AtomicLongMap.java
*/ @CanIgnoreReturnValue public long incrementAndGet(K key) { return addAndGet(key, 1); } /** * Decrements by one the value currently associated with {@code key}, and returns the new value. */ @CanIgnoreReturnValue public long decrementAndGet(K key) { return addAndGet(key, -1); } /**
Registered: Fri Nov 01 12:43:10 UTC 2024 - Last Modified: Mon Apr 01 16:15:01 UTC 2024 - 11.8K bytes - Viewed (0) -
android/guava-tests/test/com/google/common/collect/CountTest.java
assertEquals(20, holder.get()); holder.add(1); assertEquals(21, holder.get()); } public void testAddAndGet() { Count holder = new Count(20); assertEquals(21, holder.addAndGet(1)); } public void testGetAndSet() { Count holder = new Count(10); assertEquals(10, holder.getAndSet(20)); assertEquals(20, holder.get()); } public void testSet() {
Registered: Fri Nov 01 12:43:10 UTC 2024 - Last Modified: Mon Feb 19 20:34:55 UTC 2024 - 1.5K bytes - Viewed (0) -
android/guava/src/com/google/common/util/concurrent/AtomicLongMap.java
*/ @CanIgnoreReturnValue public long incrementAndGet(K key) { return addAndGet(key, 1); } /** * Decrements by one the value currently associated with {@code key}, and returns the new value. */ @CanIgnoreReturnValue public long decrementAndGet(K key) { return addAndGet(key, -1); } /**
Registered: Fri Nov 01 12:43:10 UTC 2024 - Last Modified: Mon Apr 01 16:15:01 UTC 2024 - 14.1K bytes - Viewed (0) -
guava-tests/test/com/google/common/util/concurrent/AtomicDoubleTest.java
assertBitEquals(x + y, a.get()); } } } /** addAndGet adds given value to current, and returns current value */ public void testAddAndGet() { for (double x : VALUES) { for (double y : VALUES) { AtomicDouble a = new AtomicDouble(x); double z = a.addAndGet(y); assertBitEquals(x + y, z); assertBitEquals(x + y, a.get()); } }
Registered: Fri Nov 01 12:43:10 UTC 2024 - Last Modified: Thu Oct 17 02:42:09 UTC 2024 - 10.3K bytes - Viewed (0) -
guava-tests/test/com/google/common/util/concurrent/AtomicLongMapBasherTest.java
case 1: map.decrementAndGet(key); threadSum--; break; case 2: map.addAndGet(key, delta); threadSum += delta; break; case 3: map.getAndIncrement(key); threadSum++;
Registered: Fri Nov 01 12:43:10 UTC 2024 - Last Modified: Tue Feb 13 14:28:25 UTC 2024 - 4.2K bytes - Viewed (0) -
guava-tests/test/com/google/common/util/concurrent/AtomicDoubleArrayTest.java
} } } } /** addAndGet adds given value to current, and returns current value */ public void testAddAndGet() { 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.addAndGet(i, y); assertBitEquals(x + y, z);
Registered: Fri Nov 01 12:43:10 UTC 2024 - Last Modified: Thu Oct 17 02:42:09 UTC 2024 - 14.6K bytes - Viewed (0) -
android/guava-testlib/src/com/google/common/testing/FakeTicker.java
} /** Advances the ticker value by {@code nanoseconds}. */ @SuppressWarnings("GoodTime") // should accept a java.time.Duration @CanIgnoreReturnValue public FakeTicker advance(long nanoseconds) { nanos.addAndGet(nanoseconds); return this; } /** * Advances the ticker value by {@code duration}. * * @since 33.1.0 (but since 28.0 in the JRE <a
Registered: Fri Nov 01 12:43:10 UTC 2024 - Last Modified: Sat Oct 19 00:26:48 UTC 2024 - 4.3K bytes - Viewed (0) -
guava-testlib/src/com/google/common/testing/FakeTicker.java
} /** Advances the ticker value by {@code nanoseconds}. */ @SuppressWarnings("GoodTime") // should accept a java.time.Duration @CanIgnoreReturnValue public FakeTicker advance(long nanoseconds) { nanos.addAndGet(nanoseconds); return this; } /** * Advances the ticker value by {@code duration}. * * @since 28.0 */ @GwtIncompatible @J2ktIncompatible @CanIgnoreReturnValue
Registered: Fri Nov 01 12:43:10 UTC 2024 - Last Modified: Sat Oct 19 00:26:48 UTC 2024 - 3.6K bytes - Viewed (0)