Folds

org.specs2.control.origami.Folds
See theFolds companion trait
object Folds extends Folds

Attributes

Companion
trait
Graph
Supertypes
trait Folds
class Object
trait Matchable
class Any
Self type
Folds.type

Members list

Value members

Inherited methods

def bracket[R : _Safe, A, C](open: Eff[R, C])(step: (C, A) => Eff[R, C])(close: C => Eff[R, Unit]): Fold[[_] =>> Eff[R, _$24], A, Unit]

Attributes

Inherited from:
Folds
def fromFoldLeft[M[_] : Monad, A, B](b: B)(f: (B, A) => M[B]): Fold[M, A, B] { type S = B; }

Attributes

Returns

a fold from arguments of a fold left

Inherited from:
Folds
def fromMonoidMap[M[_] : Monad, A, O : Monoid](f: A => O): Fold[M, A, O] { type S = O; }

Attributes

Returns

a fold which uses a Monoid to accumulate elements

Inherited from:
Folds
def fromMonoidMapEval[M[_] : Monad, A, O : Monoid](f: A => M[O]): Fold[M, A, O] { type S = O; }

Attributes

Returns

a fold which uses a Monoid to accumulate elements

Inherited from:
Folds
def fromSink[M[_] : Monad, A](action: A => M[Unit]): Fold[M, A, Unit]

Attributes

Inherited from:
Folds
def fromStart[M[_] : Monad, A, S1](action: M[S1]): Fold[M, A, S1] { type S = S1; }

Attributes

Returns

a fold with just a start action

Inherited from:
Folds
def list[A]: Fold[Id, A, List[A]]

Attributes

Returns

a Fold which simply accumulates elements into a List

Inherited from:
Folds