- Sort Score
- Result 10 results
- Languages All
Results 31 - 40 of 167 for multiset (0.05 sec)
-
android/guava-tests/test/com/google/common/collect/LinkedHashMultisetTest.java
}; } public void testCreate() { Multiset<String> multiset = LinkedHashMultiset.create(); multiset.add("foo", 2); multiset.add("bar"); assertEquals(3, multiset.size()); assertEquals(2, multiset.count("foo")); assertEquals("[foo x 2, bar]", multiset.toString()); } public void testCreateWithSize() { Multiset<String> multiset = LinkedHashMultiset.create(50); multiset.add("foo", 2);
Registered: Fri Nov 01 12:43:10 UTC 2024 - Last Modified: Sat Oct 19 00:05:46 UTC 2024 - 4.5K bytes - Viewed (0) -
android/guava/src/com/google/common/collect/TreeMultiset.java
} /** * Creates a new, empty multiset, sorted according to the specified comparator. All elements * inserted into the multiset must be <i>mutually comparable</i> by the specified comparator: * {@code comparator.compare(e1, e2)} must not throw a {@code ClassCastException} for any elements * {@code e1} and {@code e2} in the multiset. If the user attempts to add an element to the
Registered: Fri Nov 01 12:43:10 UTC 2024 - Last Modified: Fri Oct 18 20:24:49 UTC 2024 - 34.1K bytes - Viewed (0) -
guava-testlib/src/com/google/common/collect/testing/google/MultisetCountTester.java
} public void testCount_wrongType() { assertEquals( "multiset.count(wrongType) didn't return 0", 0, getMultiset().count(WrongType.VALUE)); } /** * Returns {@link Method} instances for the read tests that assume multisets support duplicates so * that the test of {@code Multisets.forSet()} can suppress them. */ @J2ktIncompatible @GwtIncompatible // reflection
Registered: Fri Nov 01 12:43:10 UTC 2024 - Last Modified: Wed Oct 30 16:15:19 UTC 2024 - 3.5K bytes - Viewed (0) -
guava/src/com/google/common/collect/HashMultiset.java
* * @param elements the elements that the multiset should contain */ public static <E extends @Nullable Object> HashMultiset<E> create( Iterable<? extends E> elements) { HashMultiset<E> multiset = create(Multisets.inferDistinctElements(elements)); Iterables.addAll(multiset, elements); return multiset; } private HashMultiset() {
Registered: Fri Nov 01 12:43:10 UTC 2024 - Last Modified: Mon Apr 01 16:15:01 UTC 2024 - 3.4K bytes - Viewed (0) -
android/guava-testlib/src/com/google/common/collect/testing/google/UnmodifiableCollectionTests.java
* * @param multiset the presumed-immutable multiset * @param sampleElement an element of the same type as that contained by {@code multiset}. {@code * multiset} may or may not have {@code sampleElement} as a member. */ public static <E extends @Nullable Object> void assertMultisetIsUnmodifiable( Multiset<E> multiset, E sampleElement) { Multiset<E> copy = LinkedHashMultiset.create(multiset);
Registered: Fri Nov 01 12:43:10 UTC 2024 - Last Modified: Wed Oct 30 16:15:19 UTC 2024 - 14.6K bytes - Viewed (0) -
guava-tests/test/com/google/common/collect/TreeMultisetTest.java
multiset.add("foo", 2); multiset.add("bar"); assertEquals(3, multiset.size()); assertEquals(2, multiset.count("foo")); assertEquals("[foo x 2, bar]", multiset.toString()); } public void testCreateFromIterable() { Multiset<String> multiset = TreeMultiset.create(asList("foo", "bar", "foo")); assertEquals(3, multiset.size()); assertEquals(2, multiset.count("foo"));
Registered: Fri Nov 01 12:43:10 UTC 2024 - Last Modified: Sat Oct 19 00:05:46 UTC 2024 - 12.9K bytes - Viewed (0) -
android/guava-testlib/src/com/google/common/collect/testing/google/MultisetEntrySetTester.java
assertEquals( "multiset.entrySet() iterator.next() returned incorrect entry", Multisets.immutableEntry(e0(), 1), iterator.next()); assertFalse( "size 1 multiset.entrySet() iterator.hasNext() returned true after next()", iterator.hasNext()); iterator.remove(); assertTrue( "multiset isn't empty after multiset.entrySet() iterator.remove()", getMultiset().isEmpty()); }
Registered: Fri Nov 01 12:43:10 UTC 2024 - Last Modified: Wed Oct 30 16:15:19 UTC 2024 - 9.5K bytes - Viewed (0) -
android/guava-tests/test/com/google/common/collect/ForwardingMultisetTest.java
Registered: Fri Nov 01 12:43:10 UTC 2024 - Last Modified: Sat Oct 19 00:05:46 UTC 2024 - 11.8K bytes - Viewed (0) -
guava-testlib/src/com/google/common/collect/testing/google/UnmodifiableCollectionTests.java
* * @param multiset the presumed-immutable multiset * @param sampleElement an element of the same type as that contained by {@code multiset}. {@code * multiset} may or may not have {@code sampleElement} as a member. */ public static <E extends @Nullable Object> void assertMultisetIsUnmodifiable( Multiset<E> multiset, E sampleElement) { Multiset<E> copy = LinkedHashMultiset.create(multiset);
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/ConcurrentHashMultisetBasherTest.java
private static class MutateTask implements Callable<int[]> { private final ConcurrentHashMultiset<String> multiset; private final ImmutableList<String> keys; private final Random random = new Random(); private MutateTask(ConcurrentHashMultiset<String> multiset, ImmutableList<String> keys) { this.multiset = multiset; this.keys = keys; } @Override public int[] call() throws Exception {
Registered: Fri Nov 01 12:43:10 UTC 2024 - Last Modified: Wed Oct 30 16:15:19 UTC 2024 - 5.9K bytes - Viewed (0)