Interface ExceptionBiPredicate<T,U,E extends Exception>

Type Parameters:
T - the first argument type
U - the second argument type
E - the exception type
Functional Interface:
This is a functional interface and can therefore be used as the assignment target for a lambda expression or method reference.

@FunctionalInterface public interface ExceptionBiPredicate<T,U,E extends Exception>
A two-argument predicate which can throw an exception.
  • Method Details

    • test

      boolean test(T t, U u) throws E
      Evaluate this predicate on the given arguments.
      Parameters:
      t - the first argument
      u - the second argument
      Returns:
      true if the predicate passes, false otherwise
      Throws:
      E - if an exception occurs
    • and

      default ExceptionBiPredicate<T,U,E> and(ExceptionBiPredicate<T,U,E> other)
      Returns a predicate which is true only when this and the given predicate return true.
      Parameters:
      other - the other predicate (must not be null)
      Returns:
      a predicate which is true only when this and the given predicate return true
    • or

      Returns a predicate which is true when either this or the given predicate return true.
      Parameters:
      other - the other predicate (must not be null)
      Returns:
      a predicate which is true when either this or the given predicate return true
    • xor

      default ExceptionBiPredicate<T,U,E> xor(ExceptionBiPredicate<T,U,E> other)
      Returns a predicate which is true when either this or the given predicate (but not both) return true.
      Parameters:
      other - the other predicate (must not be null)
      Returns:
      a predicate which is true when either this or the given predicate (but not both) return true
    • not

      default ExceptionBiPredicate<T,U,E> not()
      Returns a predicate which is true when this predicate is false, and vice-versa.
      Returns:
      a predicate which is true when this predicate is false, and vice-versa