arrow-mtl-data / arrow.mtl / WriterT

WriterT

@higherkind data class WriterT<F, W, A>

Constructors

<init> WriterT(value: Kind<F, Tuple2<W, A>>)

Functions

ap fun <B> ap(AF: Applicative<F>, SG: Semigroup<W>, ff: <ERROR CLASS><F, W, (A) -> B>): WriterT<F, W, B>
bimap fun <C, U> bimap(MF: Monad<F>, g: (W) -> U, f: (A) -> C): WriterT<F, U, C>
combineK fun combineK(SF: SemigroupK<F>, y: <ERROR CLASS><F, W, A>): WriterT<F, W, A>
content fun content(FF: Functor<F>): Kind<F, A>
flatMap fun <B> flatMap(MF: Monad<F>, SG: Semigroup<W>, f: (A) -> <ERROR CLASS><F, W, B>): WriterT<F, W, B>
liftF fun <B> liftF(AF: Applicative<F>, fa: Kind<F, B>): WriterT<F, W, B>
listen fun listen(MF: Monad<F>): <ERROR CLASS><F, W, Tuple2<W, A>>
map fun <B> map(FF: Functor<F>, f: (A) -> B): WriterT<F, W, B>
mapAcc fun <U> mapAcc(MF: Monad<F>, f: (W) -> U): WriterT<F, U, A>
reset fun reset(MF: Monad<F>, MM: Monoid<W>): WriterT<F, W, A>
semiflatMap fun <C> semiflatMap(MF: Monad<F>, SG: Semigroup<W>, f: (A) -> Kind<F, C>): WriterT<F, W, C>
subflatMap fun <B> subflatMap(MF: Monad<F>, f: (A) -> Tuple2<W, B>): WriterT<F, W, B>
swap fun swap(MF: Monad<F>): WriterT<F, A, W>
tell fun tell(MF: Monad<F>, SG: Semigroup<W>, w: W): WriterT<F, W, A>
transform fun <B, U> transform(MF: Monad<F>, f: (Tuple2<W, A>) -> Tuple2<U, B>): WriterT<F, U, B>
value fun value(): Kind<F, Tuple2<W, A>>
write fun write(FF: Functor<F>): Kind<F, W>

Companion Object Functions

both fun <F, W, A> both(AF: Applicative<F>, w: W, a: A): WriterT<F, W, A>
empty fun <F, W, A> empty(MMF: MonoidK<F>): <ERROR CLASS><F, W, A>
fromTuple fun <F, W, A> fromTuple(AF: Applicative<F>, z: Tuple2<W, A>): WriterT<F, W, A>
invoke operator fun <F, W, A> invoke(value: Kind<F, Tuple2<W, A>>): WriterT<F, W, A>
just fun <F, W, A> just(AF: Applicative<F>, MM: Monoid<W>, a: A): WriterT<F, W, A>
liftF fun <F, W, A> liftF(fa: Kind<F, A>, MM: Monoid<W>, AF: Applicative<F>): WriterT<F, W, A>
pass fun <F, W, A> pass(MF: Monad<F>, fa: <ERROR CLASS><F, W, Tuple2<(W) -> W, A>>): WriterT<F, W, A>
put fun <F, W, A> put(AF: Applicative<F>, a: A, w: W): WriterT<F, W, A>
put2 fun <F, W, A> put2(AF: Applicative<F>, a: A, w: W): WriterT<F, W, A>
putT fun <F, W, A> putT(FF: Functor<F>, vf: Kind<F, A>, w: W): WriterT<F, W, A>
putT2 fun <F, W, A> putT2(FF: Functor<F>, vf: Kind<F, A>, w: W): WriterT<F, W, A>
tailRecM fun <F, W, A, B> tailRecM(MF: Monad<F>, a: A, f: (A) -> <ERROR CLASS><F, W, Either<A, B>>): WriterT<F, W, B>
tell fun <F, W> tell(AF: Applicative<F>, l: W): WriterT<F, W, Unit>
tell2 fun <F, W> tell2(AF: Applicative<F>, l: W): WriterT<F, W, Unit>
value fun <F, W, A> value(AF: Applicative<F>, monoidW: Monoid<W>, v: A): WriterT<F, W, A>
valueT fun <F, W, A> valueT(AF: Applicative<F>, monoidW: Monoid<W>, vf: Kind<F, A>): WriterT<F, W, A>

Extension Functions

toAccumT Convert a writer computation into an accumulation computation.fun <F, S, A> WriterT<F, S, A>.toAccumT(): AccumT<S, F, A>

Do you like Arrow?

Arrow Org
<