com.jnape.palatable.lambda.functions.specialized

## Interface BiPredicate<A,B>

- Type Parameters:
    `A` - the first argument type
    `B` - the second argument type
  All Superinterfaces:
    Applicative<Fn1<B,Boolean>,Fn1<A,?>>, Cartesian<A,Fn1<B,Boolean>,Fn1<?,?>>, Cocartesian<A,Fn1<B,Boolean>,Fn1<?,?>>, Contravariant<A,Profunctor<?,Fn1<B,Boolean>,Fn1<?,?>>>, Fn1<A,Fn1<B,Boolean>>, Fn2<A,B,Boolean>, Functor<Fn1<B,Boolean>,Fn1<A,?>>, Monad<Fn1<B,Boolean>,Fn1<A,?>>, MonadReader<A,Fn1<B,Boolean>,Fn1<A,?>>, MonadRec<Fn1<B,Boolean>,Fn1<A,?>>, MonadWriter<A,Fn1<B,Boolean>,Fn1<A,?>>, Profunctor<A,Fn1<B,Boolean>,Fn1<?,?>>
  All Known Implementing Classes:
    All, And, Any, CmpEq, Eq, GT, GTE, LT, LTE, Not, Or, Xor
  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 BiPredicate<A,B>
      extends Fn2<A,B,Boolean>

  A specialized `Fn2` that returns a Boolean when fully applied, or a `Predicate` when partially applied.

- - ### Method Summary

    All Methods Static Methods Instance Methods Default Methods
    Modifier and Type | Method and Description
    --- | ---
    `default BiPredicate<A,B>` | `and(BiPredicate<? super A,? super B> other)` Left-to-right short-circuiting logical conjunction.
    `default Predicate<B>` | `apply(A a)` Partially apply this function by passing its first argument.
    `default <Z> Fn2<Z,B,Boolean>` | `contraMap(Fn1<? super Z,? extends A> fn)` Contravariantly map `A <- B`.
    `default <Z> BiPredicate<Z,B>` | `diMapL(Fn1<? super Z,? extends A> fn)` Contravariantly map over the argument to this function, producing a function that takes the new argument type, and produces the same result.
    `default <D> BiPredicate<A,B>` | `discardR(Applicative<D,Fn1<A,?>> appB)` Sequence both this `Applicative` and `appB`, discarding `appB's` result and returning this `Applicative`.
    `default BiPredicate<B,A>` | `flip()` Flip the order of the arguments.
    `static <A,B> BiPredicate<A,B>` | `fromBiPredicate(BiPredicate<A,B> biPredicate)` Create a `BiPredicate` from a java `BiPredicate`.
    `default BiPredicate<A,B>` | `negate()` Logical negation.
    `default BiPredicate<A,B>` | `or(BiPredicate<? super A,? super B> other)` Left-to-right short-circuiting logical disjunction.
    `default BiPredicate<A,B>` | `toBiPredicate()` Convert this `BiPredicate` to a java `BiPredicate`.
    `default Predicate<? super Product2<? extends A,? extends B>>` | `uncurry()` Returns an `Fn1` that takes the arguments as a ``Product2`<A, B>`.

    - ### Methods inherited from interface com.jnape.palatable.lambda.functions.Fn2

      `apply, checkedApply, checkedApply, compose, curried, curry, fn2, fromBiFunction, toBiFunction, widen`

    - ### Methods inherited from interface com.jnape.palatable.lambda.functions.Fn1

      `andThen, carry, cartesian, censor, choose, cocartesian, diMap, diMapR, discardL, flatMap, fmap, fn1, fromFunction, lazyZip, listens, local, pure, pureFn1, thunk, toFunction, trampolineM, zip, zip`

    - ### Methods inherited from interface com.jnape.palatable.lambda.monad.Monad

      `join`

    - ### Methods inherited from interface com.jnape.palatable.lambda.functor.Functor

      `coerce`

- - ### Method Detail

    - #### apply

          default Predicate<B> apply(A a)

      Partially apply this function by passing its first argument.
      Specified by:
        `apply` in interface `Fn1<A,Fn1<B,Boolean>>`
      Specified by:
        `apply` in interface `Fn2<A,B,Boolean>`
      Parameters:
        `a` - the first argument
      Returns:
        an `Fn1`<B, C>

    - #### flip

          default BiPredicate<B,A> flip()

      Flip the order of the arguments.
      Specified by:
        `flip` in interface `Fn2<A,B,Boolean>`
      Returns:
        an `Fn2`<B, A, C>

    - #### discardR

          default <D> BiPredicate<A,B> discardR(Applicative<D,Fn1<A,?>> appB)

      Sequence both this `Applicative` and `appB`, discarding `appB's` result and returning this `Applicative`. This is generally useful for sequentially performing side-effects.
      Specified by:
        `discardR` in interface `Applicative<Fn1<B,Boolean>,Fn1<A,?>>`
      Specified by:
        `discardR` in interface `Fn1<A,Fn1<B,Boolean>>`
      Specified by:
        `discardR` in interface `Fn2<A,B,Boolean>`
      Specified by:
        `discardR` in interface `Monad<Fn1<B,Boolean>,Fn1<A,?>>`
      Specified by:
        `discardR` in interface `MonadReader<A,Fn1<B,Boolean>,Fn1<A,?>>`
      Specified by:
        `discardR` in interface `MonadRec<Fn1<B,Boolean>,Fn1<A,?>>`
      Specified by:
        `discardR` in interface `MonadWriter<A,Fn1<B,Boolean>,Fn1<A,?>>`
      Type Parameters:
        `D` - the type of appB's parameter
      Parameters:
        `appB` - the other Applicative
      Returns:
        this Applicative

    - #### uncurry

          default Predicate<? super Product2<? extends A,? extends B>> uncurry()

      Returns an `Fn1` that takes the arguments as a ``Product2`<A, B>`.
      Specified by:
        `uncurry` in interface `Fn2<A,B,Boolean>`
      Returns:
        an `Fn1` taking a `Product2`

    - #### diMapL

          default <Z> BiPredicate<Z,B> diMapL(Fn1<? super Z,? extends A> fn)

      Contravariantly map over the argument to this function, producing a function that takes the new argument type, and produces the same result.
      Specified by:
        `diMapL` in interface `Cartesian<A,Fn1<B,Boolean>,Fn1<?,?>>`
      Specified by:
        `diMapL` in interface `Cocartesian<A,Fn1<B,Boolean>,Fn1<?,?>>`
      Specified by:
        `diMapL` in interface `Fn1<A,Fn1<B,Boolean>>`
      Specified by:
        `diMapL` in interface `Fn2<A,B,Boolean>`
      Specified by:
        `diMapL` in interface `Profunctor<A,Fn1<B,Boolean>,Fn1<?,?>>`
      Type Parameters:
        `Z` - the new argument type
      Parameters:
        `fn` - the contravariant argument mapping function
      Returns:
        an `Fn1`<Z, B>

    - #### contraMap

          default <Z> Fn2<Z,B,Boolean> contraMap(Fn1<? super Z,? extends A> fn)

      Contravariantly map `A <- B`.
      Specified by:
        `contraMap` in interface `Cartesian<A,Fn1<B,Boolean>,Fn1<?,?>>`
      Specified by:
        `contraMap` in interface `Cocartesian<A,Fn1<B,Boolean>,Fn1<?,?>>`
      Specified by:
        `contraMap` in interface `Contravariant<A,Profunctor<?,Fn1<B,Boolean>,Fn1<?,?>>>`
      Specified by:
        `contraMap` in interface `Fn1<A,Fn1<B,Boolean>>`
      Specified by:
        `contraMap` in interface `Fn2<A,B,Boolean>`
      Specified by:
        `contraMap` in interface `Profunctor<A,Fn1<B,Boolean>,Fn1<?,?>>`
      Type Parameters:
        `Z` - the new parameter type
      Parameters:
        `fn` - the mapping function
      Returns:
        the mapped Contravariant functor instance

    - #### and

          default BiPredicate<A,B> and(BiPredicate<? super A,? super B> other)

      Left-to-right short-circuiting logical conjunction.
      Parameters:
        `other` - the biPredicate to test if this one succeeds
      Returns:
        a biPredicate representing the conjunction of this biPredicate and other

    - #### or

          default BiPredicate<A,B> or(BiPredicate<? super A,? super B> other)

      Left-to-right short-circuiting logical disjunction.
      Parameters:
        `other` - the biPredicate to test if this one fails
      Returns:
        a biPredicate representing the disjunction of this biPredicate and other

    - #### negate

          default BiPredicate<A,B> negate()

      Logical negation.
      Returns:
        the negation of this biPredicate

    - #### toBiPredicate

          default BiPredicate<A,B> toBiPredicate()

      Convert this `BiPredicate` to a java `BiPredicate`.
      Returns:
        `BiPredicate`

    - #### fromBiPredicate

          static <A,B> BiPredicate<A,B> fromBiPredicate(BiPredicate<A,B> biPredicate)

      Create a `BiPredicate` from a java `BiPredicate`.
      Type Parameters:
        `A` - the first input type
        `B` - the second input type
      Parameters:
        `biPredicate` - the `BiPredicate`
      Returns:
        the `BiPredicate`