- Sort Score
- Result 10 results
- Languages All
Results 31 - 40 of 121 for setCount (0.2 sec)
-
android/guava/src/com/google/common/collect/ConcurrentHashMultiset.java
* * @return the count of {@code element} in the multiset before this call * @throws IllegalArgumentException if {@code count} is negative */ @CanIgnoreReturnValue @Override public int setCount(E element, int count) { checkNotNull(element); checkNonnegative(count, "count"); while (true) { AtomicInteger existingCounter = safeGet(countMap, element); if (existingCounter == null) {
Registered: Fri Nov 01 12:43:10 UTC 2024 - Last Modified: Wed Oct 30 16:15:19 UTC 2024 - 21.1K bytes - Viewed (0) -
guava/src/com/google/common/collect/AbstractMapBasedMultiset.java
} frequency.add(-numberRemoved); size -= numberRemoved; return oldCount; } // Roughly a 33% performance improvement over AbstractMultiset.setCount(). @CanIgnoreReturnValue @Override public int setCount(@ParametricNullness E element, int count) { checkNonnegative(count, "count"); Count existingCounter; int oldCount; if (count == 0) {
Registered: Fri Nov 01 12:43:10 UTC 2024 - Last Modified: Wed Oct 30 16:15:19 UTC 2024 - 10.4K bytes - Viewed (0) -
android/guava/src/com/google/common/collect/Multiset.java
* zero instead. */ @CanIgnoreReturnValue int setCount(@ParametricNullness E element, int count); /** * Conditionally sets the count of an element to a new value, as described in {@link * #setCount(Object, int)}, provided that the element has the expected current count. If the * current count is not {@code oldCount}, no change is made. *
Registered: Fri Nov 01 12:43:10 UTC 2024 - Last Modified: Sat Jun 17 14:40:53 UTC 2023 - 19.7K bytes - Viewed (0) -
guava/src/com/google/common/collect/Multiset.java
* zero instead. */ @CanIgnoreReturnValue int setCount(@ParametricNullness E element, int count); /** * Conditionally sets the count of an element to a new value, as described in {@link * #setCount(Object, int)}, provided that the element has the expected current count. If the * current count is not {@code oldCount}, no change is made. *
Registered: Fri Nov 01 12:43:10 UTC 2024 - Last Modified: Sat Jun 17 14:40:53 UTC 2023 - 21K bytes - Viewed (0) -
guava-testlib/src/com/google/common/collect/testing/google/MultisetNavigationTester.java
assertEquals(0, multiset.remove(entry.getElement(), entry.getCount())); assertFalse(multiset.remove(entry.getElement())); assertFalse(multiset.elementSet().remove(entry.getElement())); } void expectSetCountFailure(SortedMultiset<E> multiset, Entry<E> entry) { try { multiset.setCount(entry.getElement(), multiset.count(entry.getElement()));
Registered: Fri Nov 01 12:43:10 UTC 2024 - Last Modified: Wed Oct 30 16:15:19 UTC 2024 - 26.1K bytes - Viewed (0) -
cmd/peer-s3-server.go
return nil }, index) } errs := g.Wait() // Initialize heal result info res = madmin.HealResultItem{ Type: madmin.HealItemBucket, Bucket: bucket, DiskCount: len(localDrives), SetCount: -1, // explicitly set an invalid value -1, for bucket heal scenario } // mutate only if not a dry-run if opts.DryRun { return res, nil } for i := range beforeState {
Registered: Sun Nov 03 19:28:11 UTC 2024 - Last Modified: Thu Aug 22 21:57:20 UTC 2024 - 8.1K bytes - Viewed (0) -
android/guava-testlib/src/com/google/common/collect/testing/google/MultisetNavigationTester.java
assertEquals(0, multiset.remove(entry.getElement(), entry.getCount())); assertFalse(multiset.remove(entry.getElement())); assertFalse(multiset.elementSet().remove(entry.getElement())); } void expectSetCountFailure(SortedMultiset<E> multiset, Entry<E> entry) { try { multiset.setCount(entry.getElement(), multiset.count(entry.getElement()));
Registered: Fri Nov 01 12:43:10 UTC 2024 - Last Modified: Wed Oct 30 16:15:19 UTC 2024 - 26.1K bytes - Viewed (0) -
android/guava/src/com/google/common/collect/ObjectCountHashMap.java
} @SuppressWarnings("unchecked") // values only contains Vs @Override public int getCount() { updateLastKnownIndex(); return (lastKnownIndex == -1) ? 0 : values[lastKnownIndex]; } @SuppressWarnings("unchecked") // values only contains Vs @CanIgnoreReturnValue public int setCount(int count) { updateLastKnownIndex(); if (lastKnownIndex == -1) { put(key, count);
Registered: Fri Nov 01 12:43:10 UTC 2024 - Last Modified: Tue Jun 01 22:07:10 UTC 2021 - 15K bytes - Viewed (0) -
android/guava/src/com/google/common/collect/ImmutableSortedMultiset.java
* We keep an array of elements and counts. Periodically -- when we need more room in the * array, or when we're building, or the like -- we sort, deduplicate, and combine the counts. * Negative counts indicate a setCount operation with ~counts[i]. */ private final Comparator<? super E> comparator; @VisibleForTesting E[] elements; private int[] counts; /*
Registered: Fri Nov 01 12:43:10 UTC 2024 - Last Modified: Wed Oct 16 21:21:17 UTC 2024 - 35.4K bytes - Viewed (0) -
android/guava/src/com/google/common/collect/Synchronized.java
} } @Override public int setCount(@ParametricNullness E element, int count) { synchronized (mutex) { return delegate().setCount(element, count); } } @Override public boolean setCount(@ParametricNullness E element, int oldCount, int newCount) { synchronized (mutex) { return delegate().setCount(element, oldCount, newCount); } }
Registered: Fri Nov 01 12:43:10 UTC 2024 - Last Modified: Wed Oct 30 16:15:19 UTC 2024 - 53.4K bytes - Viewed (0)