- Sort Score
- Num 10 results
- Language All
Results 1 - 10 of 194 for Collector (0.07 seconds)
The search processing time has exceeded the limit. The displayed results may be partial.
-
android/guava-testlib/src/com/google/common/testing/CollectorTester.java
CollectorTester<T, A, R> of( Collector<T, A, R> collector, BiPredicate<? super R, ? super R> equivalence) { return new CollectorTester<>(collector, equivalence); } private final Collector<T, A, R> collector; private final BiPredicate<? super R, ? super R> equivalence; private CollectorTester( Collector<T, A, R> collector, BiPredicate<? super R, ? super R> equivalence) {
Created: Fri Apr 03 12:43:13 GMT 2026 - Last Modified: Tue Sep 16 22:01:32 GMT 2025 - 6.8K bytes - Click Count (0) -
guava/src/com/google/common/collect/MoreCollectors.java
* collector without breaking j2cl? */ private static final Collector<Object, ?, Optional<Object>> TO_OPTIONAL = Collector.of( () -> new ToOptionalState<>(null), ToOptionalState::add, ToOptionalState::combine, ToOptionalState::getOptional, Collector.Characteristics.UNORDERED); /**
Created: Fri Apr 03 12:43:13 GMT 2026 - Last Modified: Wed Feb 18 16:22:33 GMT 2026 - 6.1K bytes - Click Count (0) -
guava-testlib/src/com/google/common/testing/CollectorTester.java
private final BiPredicate<? super R, ? super R> equivalence; private CollectorTester( Collector<T, A, R> collector, BiPredicate<? super R, ? super R> equivalence) { this.collector = checkNotNull(collector); this.equivalence = checkNotNull(equivalence); } /** * Different orderings for combining the elements of an input array, which must all produce the * same result. */
Created: Fri Apr 03 12:43:13 GMT 2026 - Last Modified: Thu May 15 21:47:56 GMT 2025 - 6.6K bytes - Click Count (0) -
android/guava/src/com/google/common/collect/MoreCollectors.java
* collector without breaking j2cl? */ private static final Collector<Object, ?, Optional<Object>> TO_OPTIONAL = Collector.of( () -> new ToOptionalState<>(null), ToOptionalState::add, ToOptionalState::combine, ToOptionalState::getOptional, Collector.Characteristics.UNORDERED); /**
Created: Fri Apr 03 12:43:13 GMT 2026 - Last Modified: Wed Feb 18 16:22:33 GMT 2026 - 6.3K bytes - Click Count (0) -
guava-tests/test/com/google/common/collect/ImmutableEnumMapTest.java
Collector<Entry<AnEnum, Integer>, ?, ImmutableMap<AnEnum, Integer>> collector = toImmutableEnumMap(Entry::getKey, Entry::getValue); assertThrows( IllegalArgumentException.class, () -> Stream.of(mapEntry(AnEnum.A, 1), mapEntry(AnEnum.A, 11)).collect(collector)); } public void testToImmutableMapMerging() {
Created: Fri Apr 03 12:43:13 GMT 2026 - Last Modified: Fri Dec 26 20:08:09 GMT 2025 - 6.7K bytes - Click Count (0) -
guava-tests/test/com/google/common/collect/ImmutableSortedMapTest.java
.put("two", 2) .buildOrThrow(); CollectorTester.of(collector, equivalence) .expectCollects(expected, mapEntry("one", 1), mapEntry("two", 2), mapEntry("three", 3)); } public void testToImmutableSortedMap_withComparator() { Collector<Entry<String, Integer>, ?, ImmutableSortedMap<String, Integer>> collector = toImmutableSortedMap(String.CASE_INSENSITIVE_ORDER, Entry::getKey, Entry::getValue);
Created: Fri Apr 03 12:43:13 GMT 2026 - Last Modified: Fri Mar 13 13:01:07 GMT 2026 - 29.8K bytes - Click Count (0) -
android/guava/src/com/google/common/collect/Comparators.java
public static <T extends @Nullable Object> Collector<T, ?, List<T>> least( int k, Comparator<? super T> comparator) { checkNonnegative(k, "k"); checkNotNull(comparator); return Collector.of( () -> TopKSelector.<T>least(k, comparator), TopKSelector::offer, TopKSelector::combine, TopKSelector::topK, Collector.Characteristics.UNORDERED); } /**
Created: Fri Apr 03 12:43:13 GMT 2026 - Last Modified: Mon Feb 23 19:19:10 GMT 2026 - 11.5K bytes - Click Count (0) -
android/guava/src/com/google/common/collect/TableCollectors.java
import java.util.function.Supplier; import java.util.stream.Collector; import org.jspecify.annotations.Nullable; /** Collectors utilities for {@code common.collect.Table} internals. */ @GwtCompatible @IgnoreJRERequirement // used only from APIs with Java 8 types in them final class TableCollectors { static <T extends @Nullable Object, R, C, V> Collector<T, ?, ImmutableTable<R, C, V>> toImmutableTable(Created: Fri Apr 03 12:43:13 GMT 2026 - Last Modified: Mon Apr 14 16:07:06 GMT 2025 - 7.6K bytes - Click Count (0) -
guava-tests/test/com/google/common/collect/ImmutableSetTest.java
assertThat(copy).isNotSameInstanceAs(sortedSet); } public void testToImmutableSet() { Collector<String, ?, ImmutableSet<String>> collector = toImmutableSet(); Equivalence<ImmutableSet<String>> equivalence = Equivalence.equals().onResultOf(ImmutableSet::asList); CollectorTester.of(collector, equivalence) .expectCollects(ImmutableSet.of("a", "b", "c", "d"), "a", "b", "a", "c", "b", "b", "d"); }
Created: Fri Apr 03 12:43:13 GMT 2026 - Last Modified: Fri Mar 13 13:01:07 GMT 2026 - 14.2K bytes - Click Count (0) -
guava/src/com/google/common/collect/ImmutableSortedMap.java
* the collection operation is performed. (This differs from the {@code Collector} returned by * {@link Collectors#toMap(Function, Function)}, which throws an {@code IllegalStateException}.) * * @since NEXT */ public static <T extends @Nullable Object, K extends Comparable<? super K>, V> Collector<T, ?, ImmutableSortedMap<K, V>> toImmutableSortedMap( Function<? super T, ? extends K> keyFunction,Created: Fri Apr 03 12:43:13 GMT 2026 - Last Modified: Thu Jan 08 18:10:02 GMT 2026 - 52.1K bytes - Click Count (0)