Example usage for java.util.function DoublePredicate negate

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

Introduction

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

Prototype

default DoublePredicate 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) {
    DoublePredicate dp = (d) -> d > 0;

    System.out.println(dp.test(0.5));
    System.out.println(dp.negate().test(0.5));
}