FreeBind

sealed abstract class FreeBind[F[_], A]
Companion:
object
class Object
trait Matchable
class Any

Type members

Types

type Bound[X] = (F[X], X => FreeBind[F, A])

Value members

Concrete methods

def cata[B](f: A => B)(implicit F: Foldable[F], B: Monoid[B]): B
def flatMap[B](f: A => FreeBind[F, B]): FreeBind[F, B]
def fold(implicit F: BindRec[F]): F[A]
def foldMap[M[_]](f: NaturalTransformation[F, M])(implicit M: BindRec[M]): M[A]
def foldMapRec[M[_]](tr: NaturalTransformation[F, [α] =>> M[FreeBind[F, α] \/ α]])(implicit M: BindRec[M]): M[A]
@tailrec
final def foldRun[S](s: S, f: NaturalTransformation[[α] =>> (S, F[α]), [_] =>> (S, _$32)]): (S, A)

foldRunM specialized for Id

foldRunM specialized for Id

def foldRunM[M[_], S](s: S, f: NaturalTransformation[[α] =>> (S, F[α]), [α] =>> M[(S, α)]])(implicit M: BindRec[M]): M[(S, A)]
def foldRunRecM[M[_], S](s: S, f: NaturalTransformation[[α] =>> (S, F[α]), [α] =>> M[(S, FreeBind[F, α], S => S) \/ (S, α)]])(implicit M: BindRec[M]): M[(S, A)]
def foldRunRecParM[M[_], S1, S2](s: S1, f: NaturalTransformation[[α] =>> (S1, F[α]), [α] =>> M[(S1, FreeBind[F, α], S2 => S2) \/ (S2, α)]])(implicit M: BindRec[M], S2: Monoid[S2]): M[(S2, A)]
@tailrec
final def handle[B](onLeaf: F[A] => B, onBind: NaturalTransformation[Bound, [_] =>> Const[B, _$2]]): B
def mapF[G[_]](f: NaturalTransformation[F, G]): FreeBind[G, A]
@tailrec
final def resume: APair[F, Function1] \/ F[A]
def runState[S](s: S)(implicit ev: FreeBind[F, A] =:= FreeBind[[α] =>> S => (S, α), A]): (S, A)

runStateM specialized for Id

runStateM specialized for Id

def runStateM[M[_], S](s: S)(implicit ev: FreeBind[F, A] =:= FreeBind[[α] =>> S => M[(S, α)], A], M: BindRec[M]): M[(S, A)]

foldRunM specialized for S => M[(S, ?)]

foldRunM specialized for S => M[(S, ?)]

def traverse[G[_], B](f: A => G[B])(implicit F: Traverse[F], G: Applicative[G]): G[FreeBind[F, B]]