Class Merge<L,R>
- java.lang.Object
-
- com.jnape.palatable.lambda.monoid.builtin.Merge<L,R>
-
- Type Parameters:
L- The left parameter typeR- The right parameter type
- All Implemented Interfaces:
Fn1<Semigroup<L>,Fn1<Monoid<R>,Fn1<Either<L,R>,Fn1<Either<L,R>,Either<L,R>>>>>,Fn2<Semigroup<L>,Monoid<R>,Fn1<Either<L,R>,Fn1<Either<L,R>,Either<L,R>>>>,Fn3<Semigroup<L>,Monoid<R>,Either<L,R>,Fn1<Either<L,R>,Either<L,R>>>,Fn4<Semigroup<L>,Monoid<R>,Either<L,R>,Either<L,R>,Either<L,R>>,BiMonoidFactory<Semigroup<L>,Monoid<R>,Either<L,R>>,BiSemigroupFactory<Semigroup<L>,Monoid<R>,Either<L,R>>,Applicative<Fn1<Monoid<R>,Fn1<Either<L,R>,Fn1<Either<L,R>,Either<L,R>>>>,Fn1<Semigroup<L>,?>>,Cartesian<Semigroup<L>,Fn1<Monoid<R>,Fn1<Either<L,R>,Fn1<Either<L,R>,Either<L,R>>>>,Fn1<?,?>>,Cocartesian<Semigroup<L>,Fn1<Monoid<R>,Fn1<Either<L,R>,Fn1<Either<L,R>,Either<L,R>>>>,Fn1<?,?>>,Contravariant<Semigroup<L>,Profunctor<?,Fn1<Monoid<R>,Fn1<Either<L,R>,Fn1<Either<L,R>,Either<L,R>>>>,Fn1<?,?>>>,Functor<Fn1<Monoid<R>,Fn1<Either<L,R>,Fn1<Either<L,R>,Either<L,R>>>>,Fn1<Semigroup<L>,?>>,Profunctor<Semigroup<L>,Fn1<Monoid<R>,Fn1<Either<L,R>,Fn1<Either<L,R>,Either<L,R>>>>,Fn1<?,?>>,Monad<Fn1<Monoid<R>,Fn1<Either<L,R>,Fn1<Either<L,R>,Either<L,R>>>>,Fn1<Semigroup<L>,?>>,MonadReader<Semigroup<L>,Fn1<Monoid<R>,Fn1<Either<L,R>,Fn1<Either<L,R>,Either<L,R>>>>,Fn1<Semigroup<L>,?>>,MonadRec<Fn1<Monoid<R>,Fn1<Either<L,R>,Fn1<Either<L,R>,Either<L,R>>>>,Fn1<Semigroup<L>,?>>,MonadWriter<Semigroup<L>,Fn1<Monoid<R>,Fn1<Either<L,R>,Fn1<Either<L,R>,Either<L,R>>>>,Fn1<Semigroup<L>,?>>
public final class Merge<L,R> extends java.lang.Object implements BiMonoidFactory<Semigroup<L>,Monoid<R>,Either<L,R>>
AMonoidinstance formed byEither.merge(com.jnape.palatable.lambda.functions.Fn2<? super L, ? super L, ? extends L>, com.jnape.palatable.lambda.functions.Fn2<? super R, ? super R, ? extends R>, com.jnape.palatable.lambda.adt.Either<L, R>...), a semigroup overL, and a monoid overR. LikeEither.merge(com.jnape.palatable.lambda.functions.Fn2<? super L, ? super L, ? extends L>, com.jnape.palatable.lambda.functions.Fn2<? super R, ? super R, ? extends R>, com.jnape.palatable.lambda.adt.Either<L, R>...), this is left-biased.
-
-
Constructor Summary
Constructors Modifier Constructor Description privateMerge()
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description Monoid<Either<L,R>>checkedApply(Semigroup<L> lSemigroup, Monoid<R> rMonoid)static <L,R>
Merge<L,R>merge()static <L,R>
MonoidFactory<Monoid<R>,Either<L,R>>merge(Semigroup<L> lSemigroup)static <L,R>
Monoid<Either<L,R>>merge(Semigroup<L> lSemigroup, Monoid<R> rMonoid)static <L,R>
Fn1<Either<L,R>,Either<L,R>>merge(Semigroup<L> lSemigroup, Monoid<R> rMonoid, Either<L,R> x)static <L,R>
Either<L,R>merge(Semigroup<L> lSemigroup, Monoid<R> rMonoid, Either<L,R> x, Either<L,R> y)-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface com.jnape.palatable.lambda.functions.specialized.BiMonoidFactory
apply, apply, checkedApply, flip, uncurry
-
Methods inherited from interface com.jnape.palatable.lambda.functions.specialized.BiSemigroupFactory
checkedApply
-
Methods inherited from interface com.jnape.palatable.lambda.functions.Fn1
andThen, carry, cartesian, censor, choose, cocartesian, diMap, diMapR, discardL, flatMap, fmap, lazyZip, listens, local, pure, self, thunk, toFunction, trampolineM, zip, zip
-
Methods inherited from interface com.jnape.palatable.lambda.functions.Fn2
toBiFunction
-
-
-
-
Field Detail
-
INSTANCE
private static final Merge<?,?> INSTANCE
-
-
Method Detail
-
checkedApply
public Monoid<Either<L,R>> checkedApply(Semigroup<L> lSemigroup, Monoid<R> rMonoid)
Description copied from interface:Fn3- Specified by:
checkedApplyin interfaceBiMonoidFactory<Semigroup<L>,Monoid<R>,Either<L,R>>- Specified by:
checkedApplyin interfaceBiSemigroupFactory<Semigroup<L>,Monoid<R>,Either<L,R>>- Specified by:
checkedApplyin interfaceFn2<Semigroup<L>,Monoid<R>,Fn1<Either<L,R>,Fn1<Either<L,R>,Either<L,R>>>>- Specified by:
checkedApplyin interfaceFn3<Semigroup<L>,Monoid<R>,Either<L,R>,Fn1<Either<L,R>,Either<L,R>>>
-
merge
public static <L,R> Merge<L,R> merge()
-
merge
public static <L,R> MonoidFactory<Monoid<R>,Either<L,R>> merge(Semigroup<L> lSemigroup)
-
merge
public static <L,R> Fn1<Either<L,R>,Either<L,R>> merge(Semigroup<L> lSemigroup, Monoid<R> rMonoid, Either<L,R> x)
-
-