- Sort Score
- Result 10 results
- Languages All
Results 61 - 70 of 103 for getCount (0.14 sec)
-
android/guava-testlib/src/com/google/common/collect/testing/google/AbstractMultisetSetCountTester.java
} /** Call the {@code setCount()} method under test, and check its return value. */ abstract void setCountCheckReturnValue(E element, int count); /** * Call the {@code setCount()} method under test, but do not check its return value. Callers * should use this method over {@link #setCountCheckReturnValue(Object, int)} when they expect * {@code setCount()} to throw an exception, as checking the return value could produce an
Registered: Fri Nov 01 12:43:10 UTC 2024 - Last Modified: Sat Oct 19 00:05:46 UTC 2024 - 13K bytes - Viewed (0) -
guava/src/com/google/common/collect/ForwardingMultiset.java
} @CanIgnoreReturnValue @Override public int setCount(@ParametricNullness E element, int count) { return delegate().setCount(element, count); } @CanIgnoreReturnValue @Override public boolean setCount(@ParametricNullness E element, int oldCount, int newCount) { return delegate().setCount(element, oldCount, newCount); } /**
Registered: Fri Nov 01 12:43:10 UTC 2024 - Last Modified: Fri May 12 15:26:39 UTC 2023 - 10.4K 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
long[] cumulativeCounts = new long[entries.size() + 1]; int i = 0; for (Entry<E> entry : entries) { elementsBuilder.add(entry.getElement()); cumulativeCounts[i + 1] = cumulativeCounts[i] + entry.getCount(); i++; } return new RegularImmutableSortedMultiset<>( new RegularImmutableSortedSet<E>(elementsBuilder.build(), comparator), cumulativeCounts, 0, entries.size());
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-testlib/src/com/google/common/collect/testing/google/MultisetTestSuiteBuilder.java
Multiset.Entry<E> entry = (Entry<E>) o; checkArgument( elements.add(entry.getElement()), "Duplicate keys not allowed in EntrySetGenerator"); for (int i = 0; i < entry.getCount(); i++) { contents.add(entry.getElement()); } } return ((Multiset<E>) gen.create(contents.toArray())).entrySet(); } @SuppressWarnings("unchecked") @Override
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-testlib/src/com/google/common/collect/testing/google/UnmodifiableCollectionTests.java
assertCollectionsAreEquivalent(multiset, copy); assertSetIsUnmodifiable( multiset.entrySet(), new Multiset.Entry<E>() { @Override public int getCount() { return 1; } @Override public E getElement() { return sampleElement; } });
Registered: Fri Nov 01 12:43:10 UTC 2024 - Last Modified: Wed Oct 30 16:15:19 UTC 2024 - 14.6K bytes - Viewed (0) -
android/guava/src/com/google/common/collect/ConcurrentHashMultiset.java
*/ private List<E> snapshot() { List<E> list = newArrayListWithExpectedSize(size()); for (Multiset.Entry<E> entry : entrySet()) { E element = entry.getElement(); for (int i = entry.getCount(); i > 0; i--) { list.add(element); } } return list; } // Modification Operations /** * Adds a number of occurrences of the specified element to this multiset.
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-testlib/src/com/google/common/collect/testing/google/UnmodifiableCollectionTests.java
assertCollectionsAreEquivalent(multiset, copy); assertSetIsUnmodifiable( multiset.entrySet(), new Multiset.Entry<E>() { @Override public int getCount() { return 1; } @Override public E getElement() { return sampleElement; } });
Registered: Fri Nov 01 12:43:10 UTC 2024 - Last Modified: Wed Oct 30 16:15:19 UTC 2024 - 14.8K bytes - Viewed (0) -
guava-tests/test/com/google/common/collect/ImmutableMultisetTest.java
} public void testBuilderSetCount() { ImmutableMultiset<String> multiset = new ImmutableMultiset.Builder<String>().add("a").setCount("a", 2).setCount("b", 3).build(); assertEquals(HashMultiset.create(asList("a", "a", "b", "b", "b")), multiset); } public void testBuilderAddHandlesNullsCorrectly() {
Registered: Fri Nov 01 12:43:10 UTC 2024 - Last Modified: Wed Oct 30 16:15:19 UTC 2024 - 24.9K bytes - Viewed (0) -
guava-tests/test/com/google/common/math/StatsTest.java
// instance methods on Stats vs instance methods on DoubleSummaryStatistics DoubleSummaryStatistics streamStats = stream(array).summaryStatistics(); assertThat(stats.count()).isEqualTo(streamStats.getCount()); assertEquivalent(stats.mean(), streamStats.getAverage()); assertEquivalent(stats.sum(), streamStats.getSum()); assertEquivalent(stats.max(), streamStats.getMax());
Registered: Fri Nov 01 12:43:10 UTC 2024 - Last Modified: Wed Oct 23 16:45:30 UTC 2024 - 33.3K bytes - Viewed (0)