- Sort Score
- Result 10 results
- Languages All
Results 1 - 10 of 12 for copyOfSorted (0.12 sec)
-
guava/src/com/google/common/collect/ImmutableSortedSet.java
* When multiple elements are equivalent according to {@code compareTo()}, only the first one * specified is included. To create a copy of a {@code SortedSet} that preserves the comparator, * call {@link #copyOfSorted} instead. This method iterates over {@code elements} at most once. * * <p>Note that if {@code s} is a {@code Set<String>}, then {@code ImmutableSortedSet.copyOf(s)}
Registered: Fri Nov 01 12:43:10 UTC 2024 - Last Modified: Wed Oct 30 16:15:19 UTC 2024 - 39.1K bytes - Viewed (0) -
android/guava/src/com/google/common/collect/ImmutableSortedSet.java
* When multiple elements are equivalent according to {@code compareTo()}, only the first one * specified is included. To create a copy of a {@code SortedSet} that preserves the comparator, * call {@link #copyOfSorted} instead. This method iterates over {@code elements} at most once. * * <p>Note that if {@code s} is a {@code Set<String>}, then {@code ImmutableSortedSet.copyOf(s)}
Registered: Fri Nov 01 12:43:10 UTC 2024 - Last Modified: Wed Oct 30 16:15:19 UTC 2024 - 36.9K bytes - Viewed (0) -
android/guava/src/com/google/common/collect/CollectCollectors.java
checkNotNull(valueFunction); checkNotNull(mergeFunction); return collectingAndThen( toMap(keyFunction, valueFunction, mergeFunction, () -> new TreeMap<K, V>(comparator)), ImmutableSortedMap::copyOfSorted); } static <T extends @Nullable Object, K, V> Collector<T, ?, ImmutableBiMap<K, V>> toImmutableBiMap( Function<? super T, ? extends K> keyFunction, Function<? super T, ? extends V> valueFunction) {
Registered: Fri Nov 01 12:43:10 UTC 2024 - Last Modified: Sat Oct 19 00:05:46 UTC 2024 - 17.1K bytes - Viewed (0) -
guava-tests/test/com/google/common/collect/ImmutableSortedSetTest.java
SortedSet<String> set = ImmutableSortedSet.copyOfSorted(input); assertThat(set).containsExactly("a", "in", "jumped", "over", "quick", "the").inOrder(); } public void testCopyOfSorted_natural_comparator() { SortedSet<String> input = Sets.newTreeSet(asList("in", "the", "quick", "jumped", "over", "a")); SortedSet<String> set = ImmutableSortedSet.copyOfSorted(input); assertSame(Ordering.natural(), set.comparator());
Registered: Fri Nov 01 12:43:10 UTC 2024 - Last Modified: Wed Oct 30 16:15:19 UTC 2024 - 46.7K bytes - Viewed (0) -
guava-gwt/src-super/com/google/common/collect/super/com/google/common/collect/ImmutableSortedSet.java
return copyOfInternal(comparator, elements); } // We use NATURAL_ORDER only if the input was already using natural ordering. @SuppressWarnings("unchecked") public static <E> ImmutableSortedSet<E> copyOfSorted(SortedSet<E> sortedSet) { Comparator<? super E> comparator = sortedSet.comparator(); if (comparator == null) { comparator = (Comparator<? super E>) NATURAL_ORDER; }
Registered: Fri Nov 01 12:43:10 UTC 2024 - Last Modified: Mon Aug 19 16:21:24 UTC 2024 - 15.5K bytes - Viewed (0) -
guava-tests/test/com/google/common/collect/ImmutableSortedMultisetTest.java
.thenReturn(Ordering.<Comparable<String>>natural()); when(toCopy.entrySet()).thenReturn(entrySet); ImmutableSortedMultiset<String> unused = ImmutableSortedMultiset.copyOfSorted(toCopy); assertTrue(entrySet.toArrayCalled); } private static class IntegerDiv10 implements Comparable<IntegerDiv10> { final int value; IntegerDiv10(int value) {
Registered: Fri Nov 01 12:43:10 UTC 2024 - Last Modified: Wed Oct 30 16:15:19 UTC 2024 - 22.7K bytes - Viewed (0) -
android/guava/src/com/google/common/collect/ImmutableSortedMultiset.java
} /** * Returns an immutable sorted multiset containing the given elements sorted by their natural * ordering. To create a copy of a {@code SortedMultiset} that preserves the comparator, call * {@link #copyOfSorted} instead. This method iterates over {@code elements} at most once. * * <p>Note that if {@code s} is a {@code Multiset<String>}, then {@code
Registered: Fri Nov 01 12:43:10 UTC 2024 - Last Modified: Wed Oct 16 21:21:17 UTC 2024 - 35.4K bytes - Viewed (0) -
guava/src/com/google/common/collect/ImmutableCollection.java
* usually include: * * <ul> * <li>Static methods named {@code of}, accepting an explicit list of elements or entries. * <li>Static methods named {@code copyOf} (or {@code copyOfSorted}), accepting an existing * collection whose contents should be copied. * <li>A static nested {@code Builder} class which can be used to populate a new immutable * instance. * </ul> *
Registered: Fri Nov 01 12:43:10 UTC 2024 - Last Modified: Mon Aug 12 16:59:15 UTC 2024 - 18.8K bytes - Viewed (0) -
guava/src/com/google/common/collect/ImmutableSortedMap.java
* undocumented and subject to change. * * @throws NullPointerException if any key or value in {@code map} is null */ @SuppressWarnings("unchecked") public static <K, V> ImmutableSortedMap<K, V> copyOfSorted(SortedMap<K, ? extends V> map) { Comparator<? super K> comparator = map.comparator(); if (comparator == null) { // If map has a null comparator, the keys should have a natural ordering,
Registered: Fri Nov 01 12:43:10 UTC 2024 - Last Modified: Wed Oct 30 16:15:19 UTC 2024 - 50.4K bytes - Viewed (0) -
android/guava/src/com/google/common/collect/ImmutableSortedMap.java
* undocumented and subject to change. * * @throws NullPointerException if any key or value in {@code map} is null */ @SuppressWarnings("unchecked") public static <K, V> ImmutableSortedMap<K, V> copyOfSorted(SortedMap<K, ? extends V> map) { Comparator<? super K> comparator = map.comparator(); if (comparator == null) { // If map has a null comparator, the keys should have a natural ordering,
Registered: Fri Nov 01 12:43:10 UTC 2024 - Last Modified: Wed Oct 30 16:15:19 UTC 2024 - 53K bytes - Viewed (0)