code: public final Either<L, R> filter(Function<? super R, ? extends Boolean> pred,
                                       Function<? super R, ? extends L> leftFn) {
          return flatMap(r -> pred.apply(r) ? right(r) : left(leftFn.apply(r)));
      }
docs: If this is a right value, apply <code>pred</code> to it. If the result is <code>true</code>, return the same
  value; otherwise, return the results of applying the right value to <code>leftFn</code> wrapped as a left value.
  
  @param pred   the predicate to apply to a right value
  @param leftFn the function from the right value to a left value if pred fails
  @return this is a left value or a right value that pred matches; otherwise, the result of leftFn applied to the
  right value, wrapped in a left