Home
last modified time | relevance | path

Searched refs:apply (Results 1 – 25 of 156) sorted by relevance

1234567

/libcore/ojluni/src/test/java/util/stream/test/org/openjdk/tests/java/util/stream/
DSortedOpTest.java112 terminal.apply(s.apply(transform.apply(input.get()))); in testStreamTooLarge()
157 assertEquals(knownSize.apply(1).findFirst(), Optional.of(1)); in testSequentialShortCircuitTerminal()
158 assertEquals(knownSize.apply(1).findAny(), Optional.of(1)); in testSequentialShortCircuitTerminal()
159 assertEquals(unknownSize.apply(1).findFirst(), Optional.of(1)); in testSequentialShortCircuitTerminal()
160 assertEquals(unknownSize.apply(1).findAny(), Optional.of(1)); in testSequentialShortCircuitTerminal()
163 assertEquals(knownSize.apply(2).anyMatch(i -> i == 2), true); in testSequentialShortCircuitTerminal()
164 assertEquals(knownSize.apply(2).noneMatch(i -> i == 2), false); in testSequentialShortCircuitTerminal()
165 assertEquals(knownSize.apply(2).allMatch(i -> i == 2), false); in testSequentialShortCircuitTerminal()
166 assertEquals(unknownSize.apply(2).anyMatch(i -> i == 2), true); in testSequentialShortCircuitTerminal()
167 assertEquals(unknownSize.apply(2).noneMatch(i -> i == 2), false); in testSequentialShortCircuitTerminal()
[all …]
DInfiniteStreamWithLimitOpTest.java69 data.add(new Object[]{f.apply("Stream.limit(%d)"), in sliceFunctionsDataProvider()
71 data.add(new Object[]{f.apply("Stream.skip(%1$d).limit(%1$d)"), in sliceFunctionsDataProvider()
83 data.add(new Object[]{f.apply("IntStream.limit(%d)"), in intSliceFunctionsDataProvider()
85 data.add(new Object[]{f.apply("IntStream.skip(%1$d).limit(%1$d)"), in intSliceFunctionsDataProvider()
97 data.add(new Object[]{f.apply("LongStream.limit(%d)"), in longSliceFunctionsDataProvider()
99 data.add(new Object[]{f.apply("LongStream.skip(%1$d).limit(%1$d)"), in longSliceFunctionsDataProvider()
111 data.add(new Object[]{f.apply("DoubleStream.limit(%d)"), in doubleSliceFunctionsDataProvider()
113 data.add(new Object[]{f.apply("DoubleStream.skip(%1$d).limit(%1$d)"), in doubleSliceFunctionsDataProvider()
188 stream(s -> fs.apply(s)).
199 stream(s -> fs.apply(s)).
[all …]
DStreamLinkTest.java52 private <S> Function<S, S> apply(int n, Function<S, S> f) { in apply() method in StreamLinkTest
55 s = f.apply(s); in apply()
70 stream(apply(n, (Stream<Integer> s) -> s.map(e -> (Integer) (e + 1)))).
83 stream(apply(n, (IntStream s) -> s.map(e -> e + 1))). in testIntManyStreams()
96 stream(apply(n, (LongStream s) -> s.map(e -> e + 1L))). in testLongManyStreams()
109 stream(apply(n, (DoubleStream s) -> s.map(e -> e + 1.0))). in testDoubleManyStreams()
DMatchOpTest.java101 boolean match = this.<T>kinds().get(kind).apply(predicates[i]).apply(source.stream()); in assertPredicates()
126 exerciseTerminalOps(data, this.<Integer>kinds().get(kind).apply(p)); in testStream()
127 … exerciseTerminalOps(data, s -> s.filter(pFalse), this.<Integer>kinds().get(kind).apply(p)); in testStream()
128 … exerciseTerminalOps(data, s -> s.filter(pEven), this.<Integer>kinds().get(kind).apply(p)); in testStream()
186 boolean match = intKinds.get(kind).apply(predicates[i]).apply(source.get()); in assertIntPredicates()
211 exerciseTerminalOps(data, intKinds.get(kind).apply(p)); in testIntStream()
212 exerciseTerminalOps(data, s -> s.filter(ipFalse), intKinds.get(kind).apply(p)); in testIntStream()
213 exerciseTerminalOps(data, s -> s.filter(ipEven), intKinds.get(kind).apply(p)); in testIntStream()
271 boolean match = longKinds.get(kind).apply(predicates[i]).apply(source.get()); in assertLongPredicates()
296 exerciseTerminalOps(data, longKinds.get(kind).apply(p)); in testLongStream()
[all …]
DFindFirstOpTest.java68 Iterator<Integer> i = fs.apply(data.stream()).iterator(); in exerciseStream()
74 assertContains(act, fs.apply(data.stream()).iterator()); in exerciseStream()
94 PrimitiveIterator.OfInt i = fs.apply(data.stream()).iterator(); in exerciseIntStream()
99 assertFalse(fs.apply(data.stream()).iterator().hasNext()); in exerciseIntStream()
114 PrimitiveIterator.OfLong i = fs.apply(data.stream()).iterator(); in exerciseLongStream()
119 assertFalse(fs.apply(data.stream()).iterator().hasNext()); in exerciseLongStream()
134 PrimitiveIterator.OfDouble i = fs.apply(data.stream()).iterator(); in exerciseDoubleStream()
139 assertFalse(fs.apply(data.stream()).iterator().hasNext()); in exerciseDoubleStream()
DStreamSpliteratorTest.java272 Spliterator<Integer> sp = intermediateOp.apply(l.stream()).spliterator(); in testSplitting()
297 Stream<Integer> out = f.apply(in);
304 Stream<Integer> out = f.apply(in);
314 SpliteratorTestHelper.testSpliterator(() -> f.apply(data.stream()).spliterator()); in testSpliterators()
321 … SpliteratorTestHelper.testSpliterator(() -> f.apply(data.parallelStream()).spliterator()); in testParSpliterators()
368 … Spliterator.OfInt sp = intermediateOp.apply(IntStream.range(0, 1000)).spliterator(); in testIntSplitting()
393 IntStream out = f.apply(in);
400 IntStream out = f.apply(in);
410 SpliteratorTestHelper.testIntSpliterator(() -> f.apply(data.stream()).spliterator()); in testIntSpliterators()
417 … SpliteratorTestHelper.testIntSpliterator(() -> f.apply(data.parallelStream()).spliterator()); in testIntParSpliterators()
[all …]
DCollectorExample.java76 R r1 = finisher.apply(a1); in testSnippet1()
82 R r2 = finisher.apply(combiner.apply(a2, a3)); in testSnippet1()
95 collector.finisher().apply(container); in testSnippet3()
/libcore/ojluni/src/test/java/util/Collection/testlibrary/
DCollectionSupplier.java134 … cases.add(new TestCase<>("empty", supplier, supplier.apply(Collections.emptyList()))); in get()
136 cases.add(new TestCase<>("single", supplier, supplier.apply(Arrays.asList(42)))); in get()
142 cases.add(new TestCase<>("regular", supplier, supplier.apply(regular))); in get()
148 cases.add(new TestCase<>("reverse", supplier, supplier.apply(reverse))); in get()
154 cases.add(new TestCase<>("odds", supplier, supplier.apply(odds))); in get()
160 cases.add(new TestCase<>("evens", supplier, supplier.apply(evens))); in get()
174 cases.add(new TestCase<>("fibonacci", supplier, supplier.apply(fibonacci))); in get()
179 C t = supplier.apply(Collections.emptyList()); in get()
190 final C emptyWithSlack = supplier.apply(Collections.emptyList()); in get()
195 final C singleWithSlack = supplier.apply(Collections.emptyList()); in get()
[all …]
/libcore/ojluni/src/main/java/java/util/function/
DFunction.java49 R apply(T t); in apply() method
68 return (V v) -> apply(before.apply(v)); in compose()
88 return (T t) -> after.apply(apply(t)); in andThen()
DBiFunction.java53 R apply(T t, U u); in apply() method
70 return (T t, U u) -> after.apply(apply(t, u)); in andThen()
/libcore/ojluni/src/test/java/util/stream/bootlib/java/util/stream/
DLongStreamTestScenario.java49 LongStream s = m.apply(data.stream()); in STREAM_FOR_EACH_WITH_CLOSE()
61 for (long t : m.apply(data.stream()).toArray()) { in STREAM_TO_ARRAY()
70 … for (PrimitiveIterator.OfLong seqIter = m.apply(data.stream()).iterator(); seqIter.hasNext(); ) in STREAM_ITERATOR()
79 … for (Spliterator.OfLong spl = m.apply(data.stream()).spliterator(); spl.tryAdvance(b); ) { in STREAM_SPLITERATOR()
88 SpliteratorTestHelper.mixedTraverseAndSplit(b, m.apply(data.stream()).spliterator()); in STREAM_SPLITERATOR_WITH_MIXED_TRAVERSE_AND_SPLIT()
96 m.apply(data.stream()).spliterator().forEachRemaining(b); in STREAM_SPLITERATOR_FOREACH()
103 m.apply(data.parallelStream()).sequential().forEach(b); in PAR_STREAM_SEQUENTIAL_FOR_EACH()
112 m.apply(data.parallelStream()).forEachOrdered(b); in PAR_STREAM_FOR_EACH_ORDERED()
120 … for (Spliterator.OfLong spl = m.apply(data.parallelStream()).spliterator(); spl.tryAdvance(b); ) { in PAR_STREAM_SPLITERATOR()
129 m.apply(data.parallelStream()).spliterator().forEachRemaining(b); in PAR_STREAM_SPLITERATOR_FOREACH()
[all …]
DDoubleStreamTestScenario.java49 DoubleStream s = m.apply(data.stream()); in STREAM_FOR_EACH_WITH_CLOSE()
61 for (double t : m.apply(data.stream()).toArray()) { in STREAM_TO_ARRAY()
70 … for (PrimitiveIterator.OfDouble seqIter = m.apply(data.stream()).iterator(); seqIter.hasNext(); ) in STREAM_ITERATOR()
79 … for (Spliterator.OfDouble spl = m.apply(data.stream()).spliterator(); spl.tryAdvance(b); ) { in STREAM_SPLITERATOR()
88 SpliteratorTestHelper.mixedTraverseAndSplit(b, m.apply(data.stream()).spliterator()); in STREAM_SPLITERATOR_WITH_MIXED_TRAVERSE_AND_SPLIT()
96 m.apply(data.stream()).spliterator().forEachRemaining(b); in STREAM_SPLITERATOR_FOREACH()
103 m.apply(data.parallelStream()).sequential().forEach(b); in PAR_STREAM_SEQUENTIAL_FOR_EACH()
112 m.apply(data.parallelStream()).forEachOrdered(b); in PAR_STREAM_FOR_EACH_ORDERED()
120 …for (Spliterator.OfDouble spl = m.apply(data.parallelStream()).spliterator(); spl.tryAdvance(b); )… in PAR_STREAM_SPLITERATOR()
129 m.apply(data.parallelStream()).spliterator().forEachRemaining(b); in PAR_STREAM_SPLITERATOR_FOREACH()
[all …]
DIntStreamTestScenario.java49 IntStream s = m.apply(data.stream()); in STREAM_FOR_EACH_WITH_CLOSE()
61 for (int t : m.apply(data.stream()).toArray()) { in STREAM_TO_ARRAY()
70 … for (PrimitiveIterator.OfInt seqIter = m.apply(data.stream()).iterator(); seqIter.hasNext(); ) in STREAM_ITERATOR()
79 … for (Spliterator.OfInt spl = m.apply(data.stream()).spliterator(); spl.tryAdvance(b); ) { in STREAM_SPLITERATOR()
88 SpliteratorTestHelper.mixedTraverseAndSplit(b, m.apply(data.stream()).spliterator()); in STREAM_SPLITERATOR_WITH_MIXED_TRAVERSE_AND_SPLIT()
96 m.apply(data.stream()).spliterator().forEachRemaining(b); in STREAM_SPLITERATOR_FOREACH()
103 m.apply(data.parallelStream()).sequential().forEach(b); in PAR_STREAM_SEQUENTIAL_FOR_EACH()
112 m.apply(data.parallelStream()).forEachOrdered(b); in PAR_STREAM_FOR_EACH_ORDERED()
120 … for (Spliterator.OfInt spl = m.apply(data.parallelStream()).spliterator(); spl.tryAdvance(b); ) { in PAR_STREAM_SPLITERATOR()
129 m.apply(data.parallelStream()).spliterator().forEachRemaining(b); in PAR_STREAM_SPLITERATOR_FOREACH()
[all …]
DStreamTestScenario.java48 Stream<U> s = m.apply(data.stream()); in STREAM_FOR_EACH_WITH_CLOSE()
61 for (U t : m.apply(data.stream()).collect(Collectors.toList())) { in STREAM_COLLECT()
71 for (Object t : m.apply(data.stream()).toArray()) { in STREAM_TO_ARRAY()
81 for (Iterator<U> seqIter = m.apply(data.stream()).iterator(); seqIter.hasNext(); ) in STREAM_ITERATOR()
90 for (Spliterator<U> spl = m.apply(data.stream()).spliterator(); spl.tryAdvance(b); ) { } in STREAM_SPLITERATOR()
98 SpliteratorTestHelper.mixedTraverseAndSplit(b, m.apply(data.stream()).spliterator()); in STREAM_SPLITERATOR_WITH_MIXED_TRAVERSE_AND_SPLIT()
106 m.apply(data.stream()).spliterator().forEachRemaining(b); in STREAM_SPLITERATOR_FOREACH()
114 m.apply(data.parallelStream()).sequential().forEach(b); in PAR_STREAM_SEQUENTIAL_FOR_EACH()
123 m.apply(data.parallelStream()).forEachOrdered(b); in PAR_STREAM_FOR_EACH_ORDERED()
131 … for (Spliterator<U> spl = m.apply(data.parallelStream()).spliterator(); spl.tryAdvance(b); ) { } in PAR_STREAM_SPLITERATOR()
[all …]
DSpliteratorTestHelper.java154 Consumer<T> addToFromForEach = boxingAdapter.apply(fromForEach::add); in testSpliterator()
208 Consumer<T> addToFromForEach = boxingAdapter.apply(fromForEach::add); in testForEach()
212 spliterator.forEachRemaining(boxingAdapter.apply( in testForEach()
215 spliterator.tryAdvance(boxingAdapter.apply( in testForEach()
238 Consumer<T> addToFromTryAdvance = boxingAdapter.apply(fromTryAdvance::add); in testTryAdvance()
242 spliterator.forEachRemaining(boxingAdapter.apply( in testTryAdvance()
245 spliterator.tryAdvance(boxingAdapter.apply( in testTryAdvance()
269 Consumer<T> addToDest = boxingAdapter.apply(dest::add); in testMixedTryAdvanceForEach()
274 spliterator.forEachRemaining(boxingAdapter.apply( in testMixedTryAdvanceForEach()
277 spliterator.tryAdvance(boxingAdapter.apply( in testMixedTryAdvanceForEach()
[all …]
/libcore/ojluni/src/test/java/util/stream/testlib/org/openjdk/testlib/java/util/stream/
DIntStreamTestScenario.java52 IntStream s = m.apply(data.stream()); in STREAM_FOR_EACH_WITH_CLOSE()
64 for (int t : m.apply(data.stream()).toArray()) { in STREAM_TO_ARRAY()
73 … for (PrimitiveIterator.OfInt seqIter = m.apply(data.stream()).iterator(); seqIter.hasNext(); ) in STREAM_ITERATOR()
82 … for (Spliterator.OfInt spl = m.apply(data.stream()).spliterator(); spl.tryAdvance(b); ) { in STREAM_SPLITERATOR()
91 SpliteratorTestHelper.mixedTraverseAndSplit(b, m.apply(data.stream()).spliterator()); in STREAM_SPLITERATOR_WITH_MIXED_TRAVERSE_AND_SPLIT()
99 m.apply(data.stream()).spliterator().forEachRemaining(b); in STREAM_SPLITERATOR_FOREACH()
106 m.apply(data.parallelStream()).sequential().forEach(b); in PAR_STREAM_SEQUENTIAL_FOR_EACH()
115 m.apply(data.parallelStream()).forEachOrdered(b); in PAR_STREAM_FOR_EACH_ORDERED()
123 … for (Spliterator.OfInt spl = m.apply(data.parallelStream()).spliterator(); spl.tryAdvance(b); ) { in PAR_STREAM_SPLITERATOR()
132 m.apply(data.parallelStream()).spliterator().forEachRemaining(b); in PAR_STREAM_SPLITERATOR_FOREACH()
[all …]
DLongStreamTestScenario.java52 LongStream s = m.apply(data.stream()); in STREAM_FOR_EACH_WITH_CLOSE()
64 for (long t : m.apply(data.stream()).toArray()) { in STREAM_TO_ARRAY()
73 … for (PrimitiveIterator.OfLong seqIter = m.apply(data.stream()).iterator(); seqIter.hasNext(); ) in STREAM_ITERATOR()
82 … for (Spliterator.OfLong spl = m.apply(data.stream()).spliterator(); spl.tryAdvance(b); ) { in STREAM_SPLITERATOR()
91 SpliteratorTestHelper.mixedTraverseAndSplit(b, m.apply(data.stream()).spliterator()); in STREAM_SPLITERATOR_WITH_MIXED_TRAVERSE_AND_SPLIT()
99 m.apply(data.stream()).spliterator().forEachRemaining(b); in STREAM_SPLITERATOR_FOREACH()
106 m.apply(data.parallelStream()).sequential().forEach(b); in PAR_STREAM_SEQUENTIAL_FOR_EACH()
115 m.apply(data.parallelStream()).forEachOrdered(b); in PAR_STREAM_FOR_EACH_ORDERED()
123 … for (Spliterator.OfLong spl = m.apply(data.parallelStream()).spliterator(); spl.tryAdvance(b); ) { in PAR_STREAM_SPLITERATOR()
132 m.apply(data.parallelStream()).spliterator().forEachRemaining(b); in PAR_STREAM_SPLITERATOR_FOREACH()
[all …]
DDoubleStreamTestScenario.java53 DoubleStream s = m.apply(data.stream()); in STREAM_FOR_EACH_WITH_CLOSE()
65 for (double t : m.apply(data.stream()).toArray()) { in STREAM_TO_ARRAY()
74 … for (PrimitiveIterator.OfDouble seqIter = m.apply(data.stream()).iterator(); seqIter.hasNext(); ) in STREAM_ITERATOR()
83 … for (Spliterator.OfDouble spl = m.apply(data.stream()).spliterator(); spl.tryAdvance(b); ) { in STREAM_SPLITERATOR()
92 SpliteratorTestHelper.mixedTraverseAndSplit(b, m.apply(data.stream()).spliterator()); in STREAM_SPLITERATOR_WITH_MIXED_TRAVERSE_AND_SPLIT()
100 m.apply(data.stream()).spliterator().forEachRemaining(b); in STREAM_SPLITERATOR_FOREACH()
107 m.apply(data.parallelStream()).sequential().forEach(b); in PAR_STREAM_SEQUENTIAL_FOR_EACH()
116 m.apply(data.parallelStream()).forEachOrdered(b); in PAR_STREAM_FOR_EACH_ORDERED()
124 …for (Spliterator.OfDouble spl = m.apply(data.parallelStream()).spliterator(); spl.tryAdvance(b); )… in PAR_STREAM_SPLITERATOR()
133 m.apply(data.parallelStream()).spliterator().forEachRemaining(b); in PAR_STREAM_SPLITERATOR_FOREACH()
[all …]
DStreamTestScenario.java51 Stream<U> s = m.apply(data.stream()); in STREAM_FOR_EACH_WITH_CLOSE()
64 for (U t : m.apply(data.stream()).collect(Collectors.toList())) { in STREAM_COLLECT()
74 for (Object t : m.apply(data.stream()).toArray()) { in STREAM_TO_ARRAY()
84 for (Iterator<U> seqIter = m.apply(data.stream()).iterator(); seqIter.hasNext(); ) in STREAM_ITERATOR()
93 for (Spliterator<U> spl = m.apply(data.stream()).spliterator(); spl.tryAdvance(b); ) { } in STREAM_SPLITERATOR()
101 SpliteratorTestHelper.mixedTraverseAndSplit(b, m.apply(data.stream()).spliterator()); in STREAM_SPLITERATOR_WITH_MIXED_TRAVERSE_AND_SPLIT()
109 m.apply(data.stream()).spliterator().forEachRemaining(b); in STREAM_SPLITERATOR_FOREACH()
117 m.apply(data.parallelStream()).sequential().forEach(b); in PAR_STREAM_SEQUENTIAL_FOR_EACH()
126 m.apply(data.parallelStream()).forEachOrdered(b); in PAR_STREAM_FOR_EACH_ORDERED()
134 … for (Spliterator<U> spl = m.apply(data.parallelStream()).spliterator(); spl.tryAdvance(b); ) { } in PAR_STREAM_SPLITERATOR()
[all …]
DSpliteratorTestHelper.java154 Consumer<T> addToFromForEach = boxingAdapter.apply(fromForEach::add); in testSpliterator()
208 Consumer<T> addToFromForEach = boxingAdapter.apply(fromForEach::add); in testForEach()
212 spliterator.forEachRemaining(boxingAdapter.apply( in testForEach()
215 spliterator.tryAdvance(boxingAdapter.apply( in testForEach()
238 Consumer<T> addToFromTryAdvance = boxingAdapter.apply(fromTryAdvance::add); in testTryAdvance()
242 spliterator.forEachRemaining(boxingAdapter.apply( in testTryAdvance()
245 spliterator.tryAdvance(boxingAdapter.apply( in testTryAdvance()
269 Consumer<T> addToDest = boxingAdapter.apply(dest::add); in testMixedTryAdvanceForEach()
274 spliterator.forEachRemaining(boxingAdapter.apply( in testMixedTryAdvanceForEach()
277 spliterator.tryAdvance(boxingAdapter.apply( in testMixedTryAdvanceForEach()
[all …]
/libcore/ojluni/src/test/java/util/Objects/
DCheckLongIndex.java97 apply("checkIndex", List.of(index, length)).getMessage();
159 apply("checkFromToIndex", List.of(fromIndex, toIndex, length)).getMessage();
223 apply("checkFromIndexSize", List.of(fromIndex, size, length)).getMessage();
268 messages.add(f.apply("checkIndex", List.of(-1L, 0L)).getMessage());
269 messages.add(f.apply("checkFromToIndex", List.of(-1L, 0L, 0L)).getMessage());
270 messages.add(f.apply("checkFromIndexSize", List.of(-1L, 0L, 0L)).getMessage());
272 messages.add(f.apply("checkUnknown", List.of(-1L, 0L, 0L)).getMessage());
274 messages.add(f.apply("checkIndex", List.of(-1L, 0L, 0L)).getMessage());
275 messages.add(f.apply("checkFromToIndex", List.of(-1L, 0L, 0L, 0L)).getMessage());
276 messages.add(f.apply("checkFromIndexSize", List.of(-1L, 0L, 0L, 0L)).getMessage());
[all …]
DCheckIndex.java98 apply("checkIndex", List.of(index, length)).getMessage();
160 apply("checkFromToIndex", List.of(fromIndex, toIndex, length)).getMessage();
229 apply("checkFromIndexSize", List.of(fromIndex, size, length)).getMessage();
274 messages.add(f.apply("checkIndex", List.of(-1, 0)).getMessage());
275 messages.add(f.apply("checkFromToIndex", List.of(-1, 0, 0)).getMessage());
276 messages.add(f.apply("checkFromIndexSize", List.of(-1, 0, 0)).getMessage());
278 messages.add(f.apply("checkUnknown", List.of(-1, 0, 0)).getMessage());
280 messages.add(f.apply("checkIndex", List.of(-1, 0, 0)).getMessage());
281 messages.add(f.apply("checkFromToIndex", List.of(-1, 0, 0, 0)).getMessage());
282 messages.add(f.apply("checkFromIndexSize", List.of(-1, 0, 0, 0)).getMessage());
[all …]
/libcore/luni/src/test/java/libcore/java/util/function/
DFunctionTest.java27 assertSame(o, Function.identity().apply(o)); in testIdentity()
28 assertNull(Function.identity().apply(null)); in testIdentity()
34 assertEquals(11.0d, plusOne.compose(twice).apply(5.0d)); in testCompose()
48 assertEquals(12.0d, plusOne.andThen(twice).apply(5.0d)); in testAndThen()
/libcore/luni/src/test/java/libcore/sun/security/x509/
DUtils.java55 Object o = objectCreator.apply(ba); in testWithEachSinglePart()
70 + suffix, objectCreator.apply(allOnes).toString()); in testWithAllParts()
76 assertEquals(prefix + suffix, objectCreator.apply(new byte[0]).toString()); in testWithNoParts()
79 assertEquals(prefix + suffix, objectCreator.apply(new byte[parts.length]).toString()); in testWithNoParts()
91 assertEquals(prefix + expectedResult + suffix, objectCreator.apply(ba).toString()); in testWithEveryOtherPart()
/libcore/ojluni/src/main/java/java/util/stream/
DCollectors.java179 K k = keyMapper.apply(element);
180 V v = Objects.requireNonNull(valueMapper.apply(element));
470 (r, t) -> downstreamAccumulator.accept(r, mapper.apply(t)),
516 try (Stream<? extends U> result = mapper.apply(t)) {
886 (a, t) -> { a[0] = op.apply(a[0], t); },
887 (a, b) -> { a[0] = op.apply(a[0], b[0]); return a; },
934 value = op.apply(value, t);
992 (a, t) -> { a[0] = op.apply(a[0], mapper.apply(t)); },
993 (a, b) -> { a[0] = op.apply(a[0], b[0]); return a; },
1143 … K key = Objects.requireNonNull(classifier.apply(t), "element cannot be mapped to a null key");
[all …]

1234567