Package

scalamu

Permalink

package scalamu

Small extensions to scalaz for working with F-algebras, where F is an endofunctor of the category Scala types (type constructor of arity 1 with a map function that obeys certain laws).

CofreeInstances declares Cofree and thereby µ as an instance of scalaz typeclasses Equal (using structural equality) and Show (using case-class-like conversion to a string). This enables ===, assert_===, and .show on µ instances.

Source
scalamu.scala
Linear Supertypes
CofreeInstances, CofreeInstances0, ToTreeCataOps, ToCofreeCataOps, ToMuOps, AnyRef, Any
Ordering
  1. Alphabetic
  2. By Inheritance
Inherited
  1. scalamu
  2. CofreeInstances
  3. CofreeInstances0
  4. ToTreeCataOps
  5. ToCofreeCataOps
  6. ToMuOps
  7. AnyRef
  8. Any
  1. Hide All
  2. Show All
Visibility
  1. Public
  2. All

Type Members

  1. type Algebra[F[_], B] = (F[B]) ⇒ B

    Permalink

    A (nongeneric) F-algebra with carrier object B.

  2. type Coalgebra[F[_], B] = (B) ⇒ F[B]

    Permalink

    A (nongeneric) F-coalgebra with carrier object B.

  3. final class CofreeCataOps[F[_], A] extends Ops[Cofree[F, A]]

    Permalink

    Wraps a value self and provides catamorphism and related recursion patterns for injection into Cofree.

    Wraps a value self and provides catamorphism and related recursion patterns for injection into Cofree.

    F

    branching endofunctor of this structure

    A

    generic item type of this structure

  4. type GenericAlgebra[A, F[_], B] = (A) ⇒ (F[B]) ⇒ B

    Permalink

    A generic F-algebra with carrier object B and type parameter A.

  5. type GenericCoalgebra[A, F[_], B] = (B) ⇒ (A, F[B])

    Permalink

    A generic F-coalgebra with carrier object B.

  6. type Mu[F[_]] = Cofree[F, Unit]

    Permalink

    Alias for µ.

  7. final class MuOps[F[_]] extends Ops[µ[F]]

    Permalink

    Wraps a value self and provides catamorphism and related recursion patterns for injection into initial F-algebras based on µ.

    Wraps a value self and provides catamorphism and related recursion patterns for injection into initial F-algebras based on µ.

    F

    endofunctor of the category Scala types for this structure (type constructor of arity 1 with a map function that obeys certain laws).

  8. trait ToCofreeCataOps extends AnyRef

    Permalink

    Trait for combining multiple implicit wrapper mathods into package object.

  9. trait ToMuOps extends AnyRef

    Permalink

    Trait for combining multiple implicit wrapper mathods into package object.

  10. trait ToTreeCataOps extends AnyRef

    Permalink

    Trait for combining multiple implicit wrapper mathods into package object.

  11. final class TreeCataOps[A] extends Ops[Tree[A]]

    Permalink

    Wraps a value self and provides catamorphism and related recursion patterns for injection into Tree.

    Wraps a value self and provides catamorphism and related recursion patterns for injection into Tree.

    A

    generic item type of this tree

  12. type µ[F[_]] = Cofree[F, Unit]

    Permalink

    The least fixpoint operator on endofunctors in the category Scala types.

    The least fixpoint operator on endofunctors in the category Scala types. This is used to form the carrier object (recursive type) for the initial F-algebra. Implemented as a partial application of Cofree to Unit.

Value Members

  1. object In

    Permalink

    Object to hold the initial F-algebra, where F is an endofunctor of the category Scala types (type constructor of arity 1 with a map function that obeys certain laws).

    Object to hold the initial F-algebra, where F is an endofunctor of the category Scala types (type constructor of arity 1 with a map function that obeys certain laws). This also serves as a companion to the fixpoint type constructor µ.

  2. implicit def ToCofreeCataOps[F[_], A](c: Cofree[F, A])(implicit arg0: Functor[F]): CofreeCataOps[F, A]

    Permalink
    Definition Classes
    ToCofreeCataOps
  3. implicit def ToMuOps[F[_]](c: µ[F])(implicit arg0: Functor[F]): MuOps[F]

    Permalink
    Definition Classes
    ToMuOps
  4. implicit def ToTreeCataOps[A](t: Tree[A]): TreeCataOps[A]

    Permalink
    Definition Classes
    ToTreeCataOps
  5. implicit final def cofreeEqual[F[+_], A](implicit A0: Equal[A], F0: Lazy[Equal[F[Cofree[F, A]]]]): Equal[Cofree[F, A]]

    Permalink
    Definition Classes
    CofreeInstances0
  6. implicit final def cofreeOrder[F[+_], A](implicit A0: Order[A], F0: Lazy[Order[F[Cofree[F, A]]]]): Order[Cofree[F, A]]

    Permalink
    Definition Classes
    CofreeInstances
  7. implicit final def cofreeShow[F[+_], A](implicit A: Show[A], F: Lazy[Show[F[Cofree[F, A]]]]): Show[Cofree[F, A]]

    Permalink
    Definition Classes
    CofreeInstances
  8. implicit def functorToStringShow[F[_], A](implicit A: Show[A], F: Functor[F]): Show[F[A]]

    Permalink

    Declaration of any Functor as an instance of Show using toString on the case classes underlying the functor.

    Declaration of any Functor as an instance of Show using toString on the case classes underlying the functor. Requires the item type of the functor to be an instance of Show. Maps the corresponding show method over the functor and then applies toString.

  9. val µ: In.type

    Permalink

    Alias for In.

Inherited from CofreeInstances

Inherited from CofreeInstances0

Inherited from ToTreeCataOps

Inherited from ToCofreeCataOps

Inherited from ToMuOps

Inherited from AnyRef

Inherited from Any

Ungrouped