Home
last modified time | relevance | path

Searched refs:predicate (Results 1 – 15 of 15) sorted by relevance

/libcore/ojluni/src/main/java/java/util/stream/
DMatchOps.java79 public static <T> TerminalOp<T, Boolean> makeRef(Predicate<? super T> predicate, in makeRef() argument
81 Objects.requireNonNull(predicate); in makeRef()
90 if (!stop && predicate.test(t) == matchKind.stopOnPredicateMatches) { in makeRef()
108 public static TerminalOp<Integer, Boolean> makeInt(IntPredicate predicate, in makeInt() argument
110 Objects.requireNonNull(predicate); in makeInt()
119 if (!stop && predicate.test(t) == matchKind.stopOnPredicateMatches) { in makeInt()
137 public static TerminalOp<Long, Boolean> makeLong(LongPredicate predicate, in makeLong() argument
139 Objects.requireNonNull(predicate); in makeLong()
149 if (!stop && predicate.test(t) == matchKind.stopOnPredicateMatches) { in makeLong()
167 public static TerminalOp<Double, Boolean> makeDouble(DoublePredicate predicate, in makeDouble() argument
[all …]
DDoublePipeline.java307 public final DoubleStream filter(DoublePredicate predicate) {
308 Objects.requireNonNull(predicate);
322 if (predicate.test(t))
496 public final boolean anyMatch(DoublePredicate predicate) {
497 return evaluate(MatchOps.makeDouble(predicate, MatchOps.MatchKind.ANY));
501 public final boolean allMatch(DoublePredicate predicate) {
502 return evaluate(MatchOps.makeDouble(predicate, MatchOps.MatchKind.ALL));
506 public final boolean noneMatch(DoublePredicate predicate) {
507 return evaluate(MatchOps.makeDouble(predicate, MatchOps.MatchKind.NONE));
DIntPipeline.java344 public final IntStream filter(IntPredicate predicate) {
345 Objects.requireNonNull(predicate);
359 if (predicate.test(t))
493 public final boolean anyMatch(IntPredicate predicate) {
494 return evaluate(MatchOps.makeInt(predicate, MatchOps.MatchKind.ANY));
498 public final boolean allMatch(IntPredicate predicate) {
499 return evaluate(MatchOps.makeInt(predicate, MatchOps.MatchKind.ALL));
503 public final boolean noneMatch(IntPredicate predicate) {
504 return evaluate(MatchOps.makeInt(predicate, MatchOps.MatchKind.NONE));
DLongPipeline.java325 public final LongStream filter(LongPredicate predicate) {
326 Objects.requireNonNull(predicate);
340 if (predicate.test(t))
475 public final boolean anyMatch(LongPredicate predicate) {
476 return evaluate(MatchOps.makeLong(predicate, MatchOps.MatchKind.ANY));
480 public final boolean allMatch(LongPredicate predicate) {
481 return evaluate(MatchOps.makeLong(predicate, MatchOps.MatchKind.ALL));
485 public final boolean noneMatch(LongPredicate predicate) {
486 return evaluate(MatchOps.makeLong(predicate, MatchOps.MatchKind.NONE));
DDoubleStream.java92 DoubleStream filter(DoublePredicate predicate); in filter() argument
614 boolean anyMatch(DoublePredicate predicate); in anyMatch() argument
637 boolean allMatch(DoublePredicate predicate); in allMatch() argument
660 boolean noneMatch(DoublePredicate predicate); in noneMatch() argument
DIntStream.java88 IntStream filter(IntPredicate predicate); in filter() argument
557 boolean anyMatch(IntPredicate predicate); in anyMatch() argument
580 boolean allMatch(IntPredicate predicate); in allMatch() argument
603 boolean noneMatch(IntPredicate predicate); in noneMatch() argument
DLongStream.java93 LongStream filter(LongPredicate predicate); in filter() argument
562 boolean anyMatch(LongPredicate predicate); in anyMatch() argument
585 boolean allMatch(LongPredicate predicate); in allMatch() argument
608 boolean noneMatch(LongPredicate predicate); in noneMatch() argument
DReferencePipeline.java169 public final Stream<P_OUT> filter(Predicate<? super P_OUT> predicate) {
170 Objects.requireNonNull(predicate);
184 if (predicate.test(u))
466 public final boolean anyMatch(Predicate<? super P_OUT> predicate) {
467 return evaluate(MatchOps.makeRef(predicate, MatchOps.MatchKind.ANY));
471 public final boolean allMatch(Predicate<? super P_OUT> predicate) {
472 return evaluate(MatchOps.makeRef(predicate, MatchOps.MatchKind.ALL));
476 public final boolean noneMatch(Predicate<? super P_OUT> predicate) {
477 return evaluate(MatchOps.makeRef(predicate, MatchOps.MatchKind.NONE));
DStream.java169 Stream<T> filter(Predicate<? super T> predicate); in filter() argument
875 boolean anyMatch(Predicate<? super T> predicate); in anyMatch() argument
898 boolean allMatch(Predicate<? super T> predicate); in allMatch() argument
921 boolean noneMatch(Predicate<? super T> predicate); in noneMatch() argument
DCollectors.java1109 Collector<T, ?, Map<Boolean, List<T>>> partitioningBy(Predicate<? super T> predicate) {
1110 return partitioningBy(predicate, toList());
1135 Collector<T, ?, Map<Boolean, D>> partitioningBy(Predicate<? super T> predicate,
1139 … downstreamAccumulator.accept(predicate.test(t) ? result.forTrue : result.forFalse, t);
/libcore/ojluni/src/main/java/java/util/
DOptional.java169 public Optional<T> filter(Predicate<? super T> predicate) { in filter() argument
170 Objects.requireNonNull(predicate); in filter()
174 return predicate.test(value) ? this : empty(); in filter()
/libcore/metrictests/memory/host/src/libcore/heapmetrics/
DHeapCategorization.java291 private boolean isOwnedByClassMatching(AhatInstance rooted, Predicate<String> predicate) { in isOwnedByClassMatching() argument
303 return predicate.test(instance.asClassObj().getName()); in isOwnedByClassMatching()
311 if (predicate.test(classObj.getName())) { in isOwnedByClassMatching()
/libcore/ojluni/src/test/java/util/stream/test/org/openjdk/tests/java/util/stream/
DTabulatorsTest.java144 private final Predicate<T> predicate; field in TabulatorsTest.PartitionAssertion
147 protected PartitionAssertion(Predicate<T> predicate, in PartitionAssertion() argument
149 this.predicate = predicate; in PartitionAssertion()
159 downstream.assertValue(map.get(true), () -> source.get().filter(predicate), ordered); in assertValue()
160 … downstream.assertValue(map.get(false), () -> source.get().filter(predicate.negate()), ordered); in assertValue()
/libcore/ojluni/src/test/java/util/stream/bootlib/java/util/stream/
DLambdaTestHelpers.java127 …public static <T, R> Function<T, R> forPredicate(Predicate<? super T> predicate, R forTrue, R forF… in forPredicate() argument
128 Objects.requireNonNull(predicate); in forPredicate()
130 return t -> predicate.test(t) ? forTrue : forFalse; in forPredicate()
/libcore/ojluni/src/test/java/util/stream/testlib/org/openjdk/testlib/java/util/stream/
DLambdaTestHelpers.java128 …public static <T, R> Function<T, R> forPredicate(Predicate<? super T> predicate, R forTrue, R forF… in forPredicate() argument
129 Objects.requireNonNull(predicate); in forPredicate()
131 return t -> predicate.test(t) ? forTrue : forFalse; in forPredicate()