Example usage for java.util.function BiPredicate negate

List of usage examples for java.util.function BiPredicate negate

Introduction

In this page you can find the example usage for java.util.function BiPredicate negate.

Prototype

default BiPredicate<T, U> negate() 

Source Link

Document

Returns a predicate that represents the logical negation of this predicate.

Usage

From source file:Main.java

public static void main(String[] args) {
    BiPredicate<Integer, Integer> bi = (x, y) -> x > y;

    System.out.println(bi.test(2, 3));
    System.out.println(bi.negate().test(2, 3));

}