Interface Predicates


public interface Predicates
The utilities class for Java Predicate
Since:
2.7.5
  • Field Details

    • EMPTY_ARRAY

      static final Predicate[] EMPTY_ARRAY
  • Method Details

    • alwaysTrue

      static <T> Predicate<T> alwaysTrue()
      Predicate always return true
      Type Parameters:
      T - the type to test
      Returns:
      true
    • alwaysFalse

      static <T> Predicate<T> alwaysFalse()
      Predicate always return false
      Type Parameters:
      T - the type to test
      Returns:
      false
    • and

      static <T> Predicate<T> and(Predicate<T>... predicates)
      a composed predicate that represents a short-circuiting logical AND of predicates
      Type Parameters:
      T - the type to test
      Parameters:
      predicates - predicates
      Returns:
      non-null
    • or

      static <T> Predicate<T> or(Predicate<T>... predicates)
      a composed predicate that represents a short-circuiting logical OR of predicates
      Type Parameters:
      T - the detected type
      Parameters:
      predicates - predicates
      Returns:
      non-null