fromPredicateK<L, R> function
If the function returns true, then the resolved Either will be a Right
containing the given value
.
If the function returns false
, then the resolved Either will be a Left
containing the value returned from executing the orElse
function.
Implementation
TaskEither<L, R> Function(R r) fromPredicateK<L, R>(
bool Function(R r) f,
L Function(R r) orElse,
) =>
(r) => fromPredicate(r, f, orElse);