Package

matryoshka

Permalink

package matryoshka

Generalized folds, unfolds, and refolds.

Linear Supertypes
Ordering
  1. Grouped
  2. Alphabetic
  3. By Inheritance
Inherited
  1. matryoshka
  2. FreeInstances
  3. CofreeInstances
  4. AnyRef
  5. Any
  1. Hide All
  2. Show All
Visibility
  1. Public
  2. All

Type Members

  1. type Algebra[F[_], A] = (F[scalaz.Scalaz.Id[A]]) ⇒ scalaz.Scalaz.Id[A]

    Permalink

  2. type AlgebraIso[F[_], A] = PIso[F[scalaz.Scalaz.Id[A]], F[scalaz.Scalaz.Id[A]], A, A]

    Permalink
  3. type AlgebraM[M[_], F[_], A] = (F[scalaz.Scalaz.Id[A]]) ⇒ M[A]

    Permalink

  4. sealed class AlgebraOps[F[_], A] extends AnyRef

    Permalink
  5. type AlgebraPrism[F[_], A] = PPrism[F[A], F[A], A, A]

    Permalink
  6. type AlgebraicTransform[T[_[_]], F[_], G[_]] = (F[scalaz.Scalaz.Id[T[G]]]) ⇒ scalaz.Scalaz.Id[G[T[G]]]

    Permalink

  7. type AlgebraicTransformM[T[_[_]], M[_], F[_], G[_]] = (F[scalaz.Scalaz.Id[T[G]]]) ⇒ M[G[T[G]]]

    Permalink

  8. type Coalgebra[F[_], A] = (A) ⇒ scalaz.Scalaz.Id[F[scalaz.Scalaz.Id[A]]]

    Permalink

  9. type CoalgebraM[M[_], F[_], A] = (A) ⇒ M[F[scalaz.Scalaz.Id[A]]]

    Permalink

  10. sealed class CoalgebraOps[F[_], A] extends AnyRef

    Permalink
  11. type CoalgebraPrism[F[_], A] = PPrism[A, A, F[A], F[A]]

    Permalink
  12. type CoalgebraicTransform[T[_[_]], F[_], G[_]] = (F[T[F]]) ⇒ scalaz.Scalaz.Id[G[scalaz.Scalaz.Id[T[F]]]]

    Permalink

  13. type CoalgebraicTransformM[T[_[_]], N[_], F[_], G[_]] = (F[T[F]]) ⇒ N[G[scalaz.Scalaz.Id[T[F]]]]

    Permalink

  14. final class CoelgotMPartiallyApplied[M[_]] extends AnyRef

    Permalink
  15. final class CofParaMPartiallyApplied[M[_]] extends AnyRef

    Permalink
  16. trait CofreeInstances extends AnyRef

    Permalink
  17. sealed class CofreeOps[F[_], A] extends AnyRef

    Permalink
  18. trait Corecursive[T[_[_]]] extends Serializable

    Permalink

    Unfolds for corecursive data types.

  19. implicit final class CorecursiveOps[T[_[_]], F[_]] extends AnyRef

    Permalink
  20. type Delay[F[_], G[_]] = NaturalTransformation[F, [A]F[G[A]]]

    Permalink

    To avoid diverging implicits with fixed-point types, we need to defer the lookup.

    To avoid diverging implicits with fixed-point types, we need to defer the lookup. We do this with a NaturalTransformation (although there are more type class-y solutions available now).

  21. type DistributiveLaw[F[_], G[_]] = NaturalTransformation[[A]F[G[A]], [A]G[F[A]]]

    Permalink

    A NaturalTransformation that sequences two types

  22. type ElgotAlgebra[W[_], F[_], A] = (W[F[A]]) ⇒ scalaz.Scalaz.Id[A]

    Permalink

  23. type ElgotAlgebraM[W[_], M[_], F[_], A] = (W[F[A]]) ⇒ M[A]

    Permalink

  24. type ElgotCoalgebra[E[_], F[_], A] = (A) ⇒ scalaz.Scalaz.Id[E[F[A]]]

    Permalink

  25. type ElgotCoalgebraM[E[_], M[_], F[_], A] = (A) ⇒ M[E[F[A]]]

    Permalink

  26. final case class Fix[F[_]](unFix: F[Fix[F]]) extends Product with Serializable

    Permalink

    This is the simplest fixpoint type, implemented with general recursion.

  27. trait FreeInstances extends AnyRef

    Permalink
  28. sealed class FreeOps[F[_], A] extends AnyRef

    Permalink
  29. trait FunctorT[T[_[_]]] extends Serializable

    Permalink

    The operations here are very similar to those in Recursive and Corecursive.

    The operations here are very similar to those in Recursive and Corecursive. The usual names (cata, ana, etc.) are prefixed with trans and behave generally the same, except 1. the A of the [un]fold is restricted to T[G], but 2. the [co]algebra shape is like F[A] => G[A] rather than F[A] => A.

    In exchange, the [un]folds are available to more types (EG, folds available to Free and unfolds available to Cofree).

    There are two additional operations – transCataT and transAnaT. The distinction between these and transCata/transAna is that this allows the algebra to return the context (the outer T) to be used, whereas transCata always uses the original context of the argument to f.

    This is noticable when T is Cofree. In this function, the result may have any head the algebra desires, whereas in transCata, it can only have the head of the argument to f.

    Docs for operations, since they seem to break scaladoc if put in the right place:

    - map – very roughly like Uniplate’s descend - transCataT – akin to Uniplate’s transform - transAnaT – akin to Uniplate’s topDownTransform - transCata – akin to Fixplate’s restructure

  30. type GAlgebra[W[_], F[_], A] = (F[W[A]]) ⇒ scalaz.Scalaz.Id[A]

    Permalink

  31. type GAlgebraIso[W[_], M[_], F[_], A] = PIso[F[W[A]], F[M[A]], A, A]

    Permalink

    An algebra and its dual form an isomorphism.

  32. type GAlgebraM[W[_], M[_], F[_], A] = (F[W[A]]) ⇒ M[A]

    Permalink

  33. type GAlgebraicTransform[T[_[_]], W[_], F[_], G[_]] = (F[W[T[G]]]) ⇒ scalaz.Scalaz.Id[G[T[G]]]

    Permalink

  34. type GAlgebraicTransformM[T[_[_]], W[_], M[_], F[_], G[_]] = (F[W[T[G]]]) ⇒ M[G[T[G]]]

    Permalink

  35. type GCoalgebra[N[_], F[_], A] = (A) ⇒ scalaz.Scalaz.Id[F[N[A]]]

    Permalink

  36. type GCoalgebraM[N[_], M[_], F[_], A] = (A) ⇒ M[F[N[A]]]

    Permalink

  37. type GCoalgebraicTransform[T[_[_]], M[_], F[_], G[_]] = (F[T[F]]) ⇒ scalaz.Scalaz.Id[G[M[T[F]]]]

    Permalink

  38. type GCoalgebraicTransformM[T[_[_]], M[_], N[_], F[_], G[_]] = (F[T[F]]) ⇒ N[G[M[T[F]]]]

    Permalink

  39. sealed trait Hole extends AnyRef

    Permalink
  40. sealed class IdOps[A] extends AnyRef

    Permalink
  41. trait Merge[F[_]] extends Serializable

    Permalink

    Like Zip, but it can fail to merge, so it’s much more general.

  42. final case class Mu[F[_]](unMu: ~>[[A](F[A]) ⇒ A, scalaz.Scalaz.Id]) extends Product with Serializable

    Permalink

    This is for inductive (finite) recursive structures, models the concept of “data”, aka, the “least fixed point”.

  43. sealed abstract class Nu[F[_]] extends AnyRef

    Permalink

    This is for coinductive (potentially infinite) recursive structures, models the concept of “codata”, aka, the “greatest fixed point”.

  44. trait Recursive[T[_[_]]] extends Serializable

    Permalink

    Folds for recursive data types.

  45. trait TraverseT[T[_[_]]] extends FunctorT[T] with Serializable

    Permalink
  46. sealed abstract class [F[_], G[_]] extends AnyRef

    Permalink

Value Members

  1. object AlgebraIso extends Serializable

    Permalink
  2. object AlgebraPrism extends Serializable

    Permalink
  3. implicit def AlgebraZip[F[_]](implicit arg0: Functor[F]): Zip[[γ](F[scalaz.Scalaz.Id[γ]]) ⇒ γ]

    Permalink

  4. object CoalgebraPrism extends Serializable

    Permalink
  5. object Corecursive extends Serializable

    Permalink
  6. implicit def ElgotAlgebraMZip[W[_], M[_], F[_]](implicit arg0: Functor[W], arg1: Applicative[M], arg2: Functor[F]): Zip[[δ](W[F[δ]]) ⇒ M[δ]]

    Permalink

  7. implicit def ElgotAlgebraZip[W[_], F[_]](implicit arg0: Functor[W], arg1: Functor[F]): Zip[[δ](W[F[δ]]) ⇒ scalaz.Scalaz.Id[δ]]

    Permalink

  8. object Embed

    Permalink

    An extractor to make it easier to pattern-match on arbitrary Recursive structures.

    An extractor to make it easier to pattern-match on arbitrary Recursive structures.

    NB: This extractor is irrufutable and doesn’t break exhaustiveness checking.

  9. object Fix extends Serializable

    Permalink
  10. object FunctorT extends Serializable

    Permalink
  11. object GAlgebraIso extends Serializable

    Permalink
  12. implicit def GAlgebraZip[W[_], F[_]](implicit arg0: Functor[W], arg1: Functor[F]): Zip[[γ](F[W[γ]]) ⇒ γ]

    Permalink

  13. val Hole: Hole

    Permalink
  14. object Merge extends Serializable

    Permalink
  15. object Mu extends Serializable

    Permalink
  16. object Nu

    Permalink
  17. object Recursive extends Serializable

    Permalink
  18. object TraverseT extends Serializable

    Permalink
  19. def alignThese[T[_[_]], F[_]](implicit arg0: Recursive[T], arg1: Align[F]): ElgotCoalgebra[[β]\/[T[F], β], F, \&/[T[F], T[F]]]

    Permalink

    Aligns “These” into a single structure, short-circuting when we hit a “This” or “That”.

  20. def attrK[F[_], A](k: A)(implicit arg0: Functor[F]): (F[Cofree[F, A]]) ⇒ scalaz.Scalaz.Id[Cofree[F, A]]

    Permalink

  21. def attrSelf[T[_[_]], F[_]](implicit arg0: Corecursive[T], arg1: Functor[F]): (F[Cofree[F, T[F]]]) ⇒ scalaz.Scalaz.Id[Cofree[F, T[F]]]

    Permalink

  22. def attributeAlgebra[F[_], A](f: (F[A]) ⇒ A)(implicit arg0: Functor[F]): (F[Cofree[F, A]]) ⇒ scalaz.Scalaz.Id[Cofree[F, A]]

    Permalink

  23. def attributeAlgebraM[F[_], M[_], A](f: (F[A]) ⇒ M[A])(implicit arg0: Functor[F], arg1: Functor[M]): (F[Cofree[F, A]]) ⇒ M[Cofree[F, A]]

    Permalink

    Turns any F-algebra, into an identical one that attributes the tree with the results for each node.

  24. def attributeAna[F[_], A](a: A)(ψ: (A) ⇒ F[A])(implicit arg0: Functor[F]): Cofree[F, A]

    Permalink

    A version of matryoshka.Corecursive.ana that annotates each node with the A it was expanded from.

    A version of matryoshka.Corecursive.ana that annotates each node with the A it was expanded from. This is also the unfold from a decomposed coelgot.

  25. def attributeAnaM[M[_], F[_], A](a: A)(ψ: (A) ⇒ M[F[A]])(implicit arg0: Monad[M], arg1: Traverse[F]): M[Cofree[F, A]]

    Permalink

    A Kleisli matryoshka.attributeAna.

  26. def attributeCoalgebra[F[_], B](ψ: Coalgebra[F, B]): Coalgebra[[γ]EnvT[B, F, γ], B]

    Permalink

  27. object attributeElgotM

    Permalink

    A function to be called like attributeElgotM[M](myElgotAlgebraM).

  28. def attributePara[T[_[_]], F[_], A](f: (F[(T[F], A)]) ⇒ A)(implicit arg0: Corecursive[T], arg1: Functor[F]): (F[Cofree[F, A]]) ⇒ Cofree[F, A]

    Permalink

    NB: Since Cofree carries the functor, the resulting algebra is a cata, not a para.

  29. def binarySequence[A](relation: (A, A) ⇒ A): Coalgebra[[β](A, β), (A, A)]

    Permalink

    Generates an infinite sequence from two seed values.

  30. def builder[F[_], A, B](fa: F[A], children: List[B])(implicit arg0: Traverse[F]): F[B]

    Permalink
  31. def chrono[F[_], A, B](a: A)(g: (F[Cofree[F, B]]) ⇒ B, f: (A) ⇒ F[Free[F, A]])(implicit arg0: Functor[F]): B

    Permalink

    Similar to a hylomorphism, this composes a futumorphism and a histomorphism.

  32. def codyna[F[_], A, B](a: A)(φ: (F[B]) ⇒ B, ψ: (A) ⇒ F[Free[F, A]])(implicit arg0: Functor[F]): B

    Permalink

    cata ⋘ futu

  33. def codynaM[M[_], F[_], A, B](a: A)(φ: (F[B]) ⇒ M[B], ψ: (A) ⇒ M[F[Free[F, A]]])(implicit arg0: Monad[M], arg1: Traverse[F]): M[B]

    Permalink

    cataM ⋘ futuM

  34. def coelgot[F[_], A, B](a: A)(φ: ((A, F[B])) ⇒ B, ψ: (A) ⇒ F[A])(implicit arg0: Functor[F]): B

    Permalink

    elgotZygo ⋘ ana

  35. def coelgotM[M[_]]: CoelgotMPartiallyApplied[M]

    Permalink

    elgotZygoM ⋘ anaM

  36. def cofCata[F[_], A, B](t: Cofree[F, A])(φ: ElgotAlgebra[[β](A, β), F, B])(implicit arg0: Functor[F]): B

    Permalink

    The fold of a decomposed coelgot, since the Cofree already has the attribute for each node.

  37. def cofCataM[F[_], M[_], A, B](t: Cofree[F, A])(φ: ElgotAlgebraM[[β](A, β), M, F, B])(implicit arg0: Traverse[F], arg1: Monad[M]): M[B]

    Permalink
  38. def cofParaM[M[_]]: CofParaMPartiallyApplied[M]

    Permalink
  39. object cofree extends CofreeInstances

    Permalink
  40. implicit def cofreeCorecursive[A](implicit arg0: Monoid[A]): Corecursive[[α[_$3]]Cofree[α, A]]

    Permalink
    Definition Classes
    CofreeInstances
  41. implicit def cofreeEqual[F[_]](implicit F: Delay[Equal, F]): Delay[Equal, [β]Cofree[F, β]]

    Permalink
    Definition Classes
    CofreeInstances
  42. implicit def cofreeRecursive[A]: Recursive[[α[_$1]]Cofree[α, A]]

    Permalink
    Definition Classes
    CofreeInstances
  43. implicit def cofreeShow[F[_]](implicit F: Delay[Show, F]): Delay[Show, [β]Cofree[F, β]]

    Permalink
    Definition Classes
    CofreeInstances
  44. implicit def cofreeTraverseT[A]: TraverseT[[α[_$5]]Cofree[α, A]]

    Permalink
    Definition Classes
    CofreeInstances
  45. def colambek[T[_[_]], F[_]](ft: F[T[F]])(implicit arg0: Corecursive[T], arg1: Recursive[T], arg2: Functor[F]): T[F]

    Permalink
  46. def count[T[_[_]], F[_]](form: T[F])(implicit arg0: Recursive[T], arg1: Functor[F], arg2: Foldable[F]): (F[(T[F], Int)]) ⇒ Int

    Permalink

    Count the instinces of form in the structure.

  47. implicit def delayEqual[F[_], A](implicit A: Equal[A], F: Delay[Equal, F]): Equal[F[A]]

    Permalink

    This implicit allows Delay implicits to be found when searching for a traditionally-defined instance.

  48. implicit def delayShow[F[_], A](implicit A: Show[A], F: Delay[Show, F]): Show[F[A]]

    Permalink

    See delayEqual.

  49. def distAna[F[_]]: DistributiveLaw[scalaz.Scalaz.Id, F]

    Permalink

  50. def distApo[T[_[_]], F[_]](implicit arg0: Recursive[T], arg1: Functor[F]): DistributiveLaw[[β]\/[T[F], β], F]

    Permalink

  51. def distCata[F[_]]: DistributiveLaw[F, scalaz.Scalaz.Id]

    Permalink

  52. def distFutu[F[_]](implicit arg0: Functor[F]): DistributiveLaw[[β]Free[F, β], F]

    Permalink

  53. def distGApo[F[_], B](g: (B) ⇒ F[B])(implicit arg0: Functor[F]): DistributiveLaw[[β]\/[B, β], F]

    Permalink

  54. def distGFutu[H[_], F[_]](k: DistributiveLaw[H, F])(implicit H: Functor[H], F: Functor[F]): DistributiveLaw[[β]Free[H, β], F]

    Permalink

  55. def distGHisto[F[_], H[_]](k: DistributiveLaw[F, H])(implicit F: Functor[F], H: Functor[H]): DistributiveLaw[F, [β]Cofree[H, β]]

    Permalink

  56. def distHisto[F[_]](implicit arg0: Functor[F]): DistributiveLaw[F, [β]Cofree[F, β]]

    Permalink

  57. def distPara[T[_[_]], F[_]](implicit arg0: Corecursive[T], arg1: Functor[F]): DistributiveLaw[F, [β](T[F], β)]

    Permalink

  58. def distParaT[T[_[_]], F[_], W[_]](t: DistributiveLaw[F, W])(implicit arg0: Functor[F], arg1: Comonad[W], T: Corecursive[T]): DistributiveLaw[F, [γ]EnvT[T[F], W, γ]]

    Permalink

  59. def distZygo[F[_], B](g: (F[B]) ⇒ B)(implicit arg0: Functor[F]): DistributiveLaw[F, [β](B, β)]

    Permalink

  60. def distZygoT[F[_], W[_], B](g: (F[B]) ⇒ B, k: DistributiveLaw[F, W])(implicit arg0: Comonad[W], F: Functor[F]): DistributiveLaw[F, [γ]EnvT[B, W, γ]]

    Permalink

  61. def dyna[F[_], A, B](a: A)(φ: (F[Cofree[F, B]]) ⇒ B, ψ: (A) ⇒ F[A])(implicit arg0: Functor[F]): B

    Permalink

    histo ⋘ ana

  62. def elgot[F[_], A, B](a: A)(φ: (F[B]) ⇒ B, ψ: (A) ⇒ \/[B, F[A]])(implicit arg0: Functor[F]): B

    Permalink

    cata ⋘ elgotGApo

  63. def foldIso[T[_[_]], F[_], A](alg: AlgebraIso[F, A])(implicit arg0: Corecursive[T], arg1: Recursive[T], arg2: Functor[F]): Iso[T[F], A]

    Permalink

    There is a fold/unfold isomorphism for any AlgebraIso.

  64. def foldPrism[T[_[_]], F[_], A](alg: AlgebraPrism[F, A])(implicit arg0: Corecursive[T], arg1: Recursive[T], arg2: Traverse[F]): Prism[T[F], A]

    Permalink

    There is a fold prism for any AlgebraPrism.

  65. object free extends FreeInstances

    Permalink
  66. def freeAna[F[_], A, B](a: A)(ψ: (A) ⇒ \/[B, F[A]])(implicit arg0: Functor[F]): Free[F, B]

    Permalink

    The unfold from a decomposed elgot.

  67. implicit def freeCorecursive[A]: Corecursive[[α[_$1]]Free[α, A]]

    Permalink
    Definition Classes
    FreeInstances
  68. implicit def freeEqual[F[_]](implicit arg0: Functor[F], F: Delay[Equal, F]): Delay[Equal, [β]Free[F, β]]

    Permalink
    Definition Classes
    FreeInstances
  69. implicit def freeShow[F[_]](implicit arg0: Functor[F], F: Delay[Show, F]): Delay[Show, [β]Free[F, β]]

    Permalink
    Definition Classes
    FreeInstances
  70. implicit def freeTraverseT[A]: TraverseT[[α[_$3]]Free[α, A]]

    Permalink
    Definition Classes
    FreeInstances
  71. def ghylo[W[_], M[_], F[_], A, B](a: A)(w: DistributiveLaw[F, W], m: DistributiveLaw[M, F], f: (F[W[B]]) ⇒ B, g: (A) ⇒ F[M[A]])(implicit arg0: Comonad[W], arg1: Functor[F], M: Monad[M]): B

    Permalink

    A generalized version of a hylomorphism that composes any coalgebra and algebra.

    A generalized version of a hylomorphism that composes any coalgebra and algebra. (gcata ⋘ gana)

  72. def ghyloM[W[_], M[_], N[_], F[_], A, B](a: A)(w: DistributiveLaw[F, W], m: DistributiveLaw[M, F], f: (F[W[B]]) ⇒ N[B], g: (A) ⇒ N[F[M[A]]])(implicit arg0: Comonad[W], arg1: Traverse[W], arg2: Traverse[M], arg3: Monad[N], arg4: Traverse[F], M: Monad[M]): N[B]

    Permalink

    A Kleisli ghylo (gcataM ⋘ ganaM)

  73. def height[F[_]](implicit arg0: Foldable[F]): (F[Int]) ⇒ Int

    Permalink

    The largest number of hops from a node to a leaf.

  74. def holes[F[_], A](fa: F[A])(implicit arg0: Traverse[F]): F[(A, (A) ⇒ F[A])]

    Permalink
  75. def holesList[F[_], A](fa: F[A])(implicit arg0: Traverse[F]): List[(A, (A) ⇒ F[A])]

    Permalink
  76. def hylo[F[_], A, B](a: A)(f: (F[B]) ⇒ B, g: (A) ⇒ F[A])(implicit arg0: Functor[F]): B

    Permalink

    Composition of an anamorphism and a catamorphism that avoids building the intermediate recursive data structure.

  77. def hyloM[M[_], F[_], A, B](a: A)(f: (F[B]) ⇒ M[B], g: (A) ⇒ M[F[A]])(implicit arg0: Monad[M], arg1: Traverse[F]): M[B]

    Permalink

    A Kleisli hylomorphism.

  78. package instances

    Permalink
  79. def interpretCata[F[_], A](t: Free[F, A])(φ: (F[A]) ⇒ A)(implicit arg0: Functor[F]): A

    Permalink

    This folds a Free that you may think of as “already partially-folded”.

    This folds a Free that you may think of as “already partially-folded”. It’s also the fold of a decomposed elgot.

  80. def lambek[T[_[_]], F[_]](tf: T[F])(implicit arg0: Corecursive[T], arg1: Recursive[T], arg2: Functor[F]): F[T[F]]

    Permalink
  81. def lambekIso[T[_[_]], F[_]](implicit arg0: Corecursive[T], arg1: Recursive[T], arg2: Functor[F]): AlgebraIso[F, T[F]]

    Permalink
  82. def mergeTuple[T[_[_]], F[_]](implicit arg0: Recursive[T], arg1: Functor[F], arg2: Merge[F]): CoalgebraM[Option, F, (T[F], T[F])]

    Permalink

    Merges a tuple of functors, if possible.

  83. def orDefault[A, B](default: B)(f: (A) ⇒ Option[B]): (A) ⇒ B

    Permalink

    Converts a failable fold into a non-failable, by returning the default upon failure.

  84. def orOriginal[A](f: (A) ⇒ Option[A]): (A) ⇒ A

    Permalink

    Converts a failable fold into a non-failable, by simply returning the argument upon failure.

  85. package patterns

    Permalink
  86. def project[F[_], A](index: Int, fa: F[A])(implicit arg0: Foldable[F]): Option[A]

    Permalink
  87. def recCorecIso[T[_[_]], F[_]](implicit arg0: Recursive[T], arg1: Corecursive[T], arg2: Functor[F]): AlgebraIso[F, T[F]]

    Permalink
  88. def repeatedly[A](f: (A) ⇒ Option[A]): (A) ⇒ A

    Permalink

    Repeatedly applies the function to the result as long as it returns Some.

    Repeatedly applies the function to the result as long as it returns Some. Finally returns the last non-None value (which may be the initial input).

  89. def size[F[_]](implicit arg0: Foldable[F]): (F[Int]) ⇒ Int

    Permalink

    The number of nodes in this structure.

  90. implicit def toAlgebraOps[F[_], A](a: Algebra[F, A]): AlgebraOps[F, A]

    Permalink
  91. implicit def toCoalgebraOps[F[_], A](a: Coalgebra[F, A]): CoalgebraOps[F, A]

    Permalink
  92. implicit def toCofreeOps[F[_], A](a: Cofree[F, A]): CofreeOps[F, A]

    Permalink
  93. implicit def toFreeOps[F[_], A](a: Free[F, A]): FreeOps[F, A]

    Permalink
  94. implicit def toIdOps[A](a: A): IdOps[A]

    Permalink
  95. def toTree[F[_]](implicit arg0: Functor[F], arg1: Foldable[F]): Algebra[F, Tree[F[Unit]]]

    Permalink

    Converts a fixed-point structure into a generic Tree.

    Converts a fixed-point structure into a generic Tree. One use of this is using .cata(toTree).drawTree rather than .show to get a pretty-printed tree.

  96. def transformToAlgebra[T[_[_]], W[_], M[_], F[_], G[_]](self: GAlgebraicTransformM[T, W, M, F, G])(implicit arg0: Corecursive[T], arg1: Functor[M], arg2: Functor[G]): GAlgebraM[W, M, F, T[G]]

    Permalink

  97. def unfoldPrism[T[_[_]], F[_], A](coalg: CoalgebraPrism[F, A])(implicit arg0: Corecursive[T], arg1: Recursive[T], arg2: Traverse[F]): Prism[A, T[F]]

    Permalink

    There is an unfold prism for any CoalgebraPrism.

  98. def zipTuple[T[_[_]], F[_]](implicit arg0: Recursive[T], arg1: Functor[F], arg2: Zip[F]): Coalgebra[F, (T[F], T[F])]

    Permalink

    Combines a tuple of zippable functors.

Inherited from FreeInstances

Inherited from CofreeInstances

Inherited from AnyRef

Inherited from Any

Algebras & Coalgebras

Generic algebras that operate over most functors.

Algebra Transformations

Operations that modify algebras in various ways to make them easier to combine with others.

Distributive Laws

Natural transformations required for generalized folds and unfolds.

Refolds

Traversals that apply an unfold and a fold in a single pass.

Ungrouped