Class RightAll<L,R>

java.lang.Object
com.jnape.palatable.lambda.semigroup.builtin.RightAll<L,R>
Type Parameters:
L - The left parameter type
R - The right parameter type
All Implemented Interfaces:
Fn1<Semigroup<R>,Fn1<Either<L,R>,Fn1<Either<L,R>,Either<L,R>>>>, Fn2<Semigroup<R>,Either<L,R>,Fn1<Either<L,R>,Either<L,R>>>, Fn3<Semigroup<R>,Either<L,R>,Either<L,R>,Either<L,R>>, SemigroupFactory<Semigroup<R>,Either<L,R>>, Applicative<Fn1<Either<L,R>,Fn1<Either<L,R>,Either<L,R>>>,Fn1<Semigroup<R>,?>>, Cartesian<Semigroup<R>,Fn1<Either<L,R>,Fn1<Either<L,R>,Either<L,R>>>,Fn1<?,?>>, Cocartesian<Semigroup<R>,Fn1<Either<L,R>,Fn1<Either<L,R>,Either<L,R>>>,Fn1<?,?>>, Contravariant<Semigroup<R>,Profunctor<?,Fn1<Either<L,R>,Fn1<Either<L,R>,Either<L,R>>>,Fn1<?,?>>>, Functor<Fn1<Either<L,R>,Fn1<Either<L,R>,Either<L,R>>>,Fn1<Semigroup<R>,?>>, Profunctor<Semigroup<R>,Fn1<Either<L,R>,Fn1<Either<L,R>,Either<L,R>>>,Fn1<?,?>>, Monad<Fn1<Either<L,R>,Fn1<Either<L,R>,Either<L,R>>>,Fn1<Semigroup<R>,?>>, MonadReader<Semigroup<R>,Fn1<Either<L,R>,Fn1<Either<L,R>,Either<L,R>>>,Fn1<Semigroup<R>,?>>, MonadRec<Fn1<Either<L,R>,Fn1<Either<L,R>,Either<L,R>>>,Fn1<Semigroup<R>,?>>, MonadWriter<Semigroup<R>,Fn1<Either<L,R>,Fn1<Either<L,R>,Either<L,R>>>,Fn1<Semigroup<R>,?>>

public final class RightAll<L,R> extends Object implements SemigroupFactory<Semigroup<R>,Either<L,R>>
A Semigroup instance formed by Either<L,R> and a semigroup over R. The application to two Either values is left-biased, such that for a given Either x and y:
  • if x is a Left value, the result is x
  • if y is a Left value, the result is y
  • if both x and y are right values, the result is the application of the x and y values in terms of the provided semigroup, wrapped in Either.right(R)

For the Monoid, see RightAll.

See Also: