cats.arrow

package cats.arrow

Members list

Type members

Classlikes

trait Arrow[F[_, _]] extends Category[F], Strong[F]

Must obey the laws defined in cats.laws.ArrowLaws.

Must obey the laws defined in cats.laws.ArrowLaws.

Attributes

Companion
object
Source
Arrow.scala
Supertypes
trait Strong[F]
trait Profunctor[F]
trait Category[F]
trait Compose[F]
trait Serializable
class Object
trait Matchable
class Any
Show all
Known subtypes
trait ArrowChoice[F]
trait CommutativeArrow[F]
Self type
Arrow[F]
object Arrow

Attributes

Companion
trait
Source
Arrow.scala
Supertypes
class Object
trait Matchable
class Any
Self type
Arrow.type
trait ArrowChoice[F[_, _]] extends Arrow[F], Choice[F]

Must obey the laws defined in cats.laws.ArrowChoiceLaws.

Must obey the laws defined in cats.laws.ArrowChoiceLaws.

Attributes

Companion
object
Source
ArrowChoice.scala
Supertypes
trait Choice[F]
trait Arrow[F]
trait Strong[F]
trait Profunctor[F]
trait Category[F]
trait Compose[F]
trait Serializable
class Object
trait Matchable
class Any
Show all
Self type
object ArrowChoice

Attributes

Companion
trait
Source
ArrowChoice.scala
Supertypes
class Object
trait Matchable
class Any
Self type
trait Category[F[_, _]] extends Compose[F]

Must obey the laws defined in cats.laws.CategoryLaws.

Must obey the laws defined in cats.laws.CategoryLaws.

Attributes

Companion
object
Source
Category.scala
Supertypes
trait Compose[F]
trait Serializable
class Object
trait Matchable
class Any
Known subtypes
trait Arrow[F]
trait ArrowChoice[F]
trait CommutativeArrow[F]
trait Choice[F]
Self type
object Category

Attributes

Companion
trait
Source
Category.scala
Supertypes
class Object
trait Matchable
class Any
Self type
Category.type
trait Choice[F[_, _]] extends Category[F]

Attributes

Companion
object
Source
Choice.scala
Supertypes
trait Category[F]
trait Compose[F]
trait Serializable
class Object
trait Matchable
class Any
Show all
Known subtypes
trait ArrowChoice[F]
object Choice

Attributes

Companion
trait
Source
Choice.scala
Supertypes
class Object
trait Matchable
class Any
Self type
Choice.type
trait CommutativeArrow[F[_, _]] extends Arrow[F]

In a Commutative Arrow F[_, _], the split operation (or ***) is commutative, which means that there is non-interference between the effect of the paired arrows.

In a Commutative Arrow F[_, _], the split operation (or ***) is commutative, which means that there is non-interference between the effect of the paired arrows.

Must obey the laws in CommutativeArrowLaws

Attributes

Companion
object
Source
CommutativeArrow.scala
Supertypes
trait Arrow[F]
trait Strong[F]
trait Profunctor[F]
trait Category[F]
trait Compose[F]
trait Serializable
class Object
trait Matchable
class Any
Show all

Attributes

Companion
trait
Source
CommutativeArrow.scala
Supertypes
class Object
trait Matchable
class Any
Self type
trait Compose[F[_, _]] extends Serializable

Must obey the laws defined in cats.laws.ComposeLaws.

Must obey the laws defined in cats.laws.ComposeLaws.

Here's how you can use >>> and <<< Example:

scala> import cats.syntax.all._
scala> val f : Int => Int = (_ + 1)
scala> val g : Int => Int = (_ * 100)
scala> (f >>> g)(3)
res0: Int = 400
scala> (f <<< g)(3)
res1: Int = 301

Attributes

Companion
object
Source
Compose.scala
Supertypes
trait Serializable
class Object
trait Matchable
class Any
Known subtypes
trait Category[F]
trait Arrow[F]
trait ArrowChoice[F]
trait CommutativeArrow[F]
trait Choice[F]
Self type
Compose[F]
object Compose

Attributes

Companion
trait
Source
Compose.scala
Supertypes
class Object
trait Matchable
class Any
Self type
Compose.type
trait FunctionK[F[_], G[_]] extends Serializable

FunctionK[F[_], G[_]] is a functor transformation from F to G in the same manner that function A => B is a morphism from values of type A to B.

FunctionK[F[_], G[_]] is a functor transformation from F to G in the same manner that function A => B is a morphism from values of type A to B. An easy way to create a FunctionK instance is to use the Polymorphic lambdas provided by typelevel/kind-projector v0.9+. E.g.

val listToOption = λ[FunctionK[List, Option]](_.headOption)

Attributes

Companion
object
Source
FunctionK.scala
Supertypes
trait Serializable
class Object
trait Matchable
class Any
Self type
FunctionK[F, G]
object FunctionK

Attributes

Companion
trait
Source
FunctionK.scala
Supertypes
class Object
trait Matchable
class Any
Self type
FunctionK.type
trait Profunctor[F[_, _]] extends Serializable

A Profunctor is a Contravariant functor on its first type parameter and a Functor on its second type parameter.

A Profunctor is a Contravariant functor on its first type parameter and a Functor on its second type parameter.

Must obey the laws defined in cats.laws.ProfunctorLaws.

Attributes

Companion
object
Source
Profunctor.scala
Supertypes
trait Serializable
class Object
trait Matchable
class Any
Known subtypes
trait Strong[F]
trait Arrow[F]
trait ArrowChoice[F]
trait CommutativeArrow[F]
Self type
object Profunctor

Attributes

Companion
trait
Source
Profunctor.scala
Supertypes
class Object
trait Matchable
class Any
Self type
Profunctor.type
trait Strong[F[_, _]] extends Profunctor[F]

Must obey the laws defined in cats.laws.StrongLaws.

Must obey the laws defined in cats.laws.StrongLaws.

Attributes

Companion
object
Source
Strong.scala
Supertypes
trait Profunctor[F]
trait Serializable
class Object
trait Matchable
class Any
Known subtypes
trait Arrow[F]
trait ArrowChoice[F]
trait CommutativeArrow[F]
object Strong

Attributes

Companion
trait
Source
Strong.scala
Supertypes
class Object
trait Matchable
class Any
Self type
Strong.type