Packages

c

cats.data

BinestedBifoldable

sealed abstract class BinestedBifoldable[F[_, _], G[_], H[_]] extends Bifoldable[[δ$12$, ε$13$]Binested[F, G, H, δ$12$, ε$13$]]

Source
Binested.scala
Linear Supertypes
Bifoldable[[δ$12$, ε$13$]Binested[F, G, H, δ$12$, ε$13$]], Serializable, Serializable, AnyRef, Any
Known Subclasses
Ordering
  1. Alphabetic
  2. By Inheritance
Inherited
  1. BinestedBifoldable
  2. Bifoldable
  3. Serializable
  4. Serializable
  5. AnyRef
  6. Any
  1. Hide All
  2. Show All
Visibility
  1. Public
  2. All

Abstract Value Members

  1. implicit abstract def F: Bifoldable[F]
  2. implicit abstract def G: Foldable[G]
  3. implicit abstract def H: Foldable[H]

Concrete Value Members

  1. final def !=(arg0: Any): Boolean
    Definition Classes
    AnyRef → Any
  2. final def ##(): Int
    Definition Classes
    AnyRef → Any
  3. final def ==(arg0: Any): Boolean
    Definition Classes
    AnyRef → Any
  4. final def asInstanceOf[T0]: T0
    Definition Classes
    Any
  5. def bifold[A, B](fab: Binested[F, G, H, A, B])(implicit A: Monoid[A], B: Monoid[B]): (A, B)
    Definition Classes
    Bifoldable
  6. def bifoldLeft[A, B, C](fab: Binested[F, G, H, A, B], c: C)(f: (C, A) ⇒ C, g: (C, B) ⇒ C): C

    Collapse the structure with a left-associative function

    Collapse the structure with a left-associative function

    Example:

    scala> import cats.Bifoldable
    scala> val fab = (List(1), 2)
    
    Folding by addition to zero:
    scala> Bifoldable[Tuple2].bifoldLeft(fab, Option(0))((c, a) => c.map(_ + a.head), (c, b) => c.map(_ + b))
    res0: Option[Int] = Some(3)

    With syntax extensions, bifoldLeft can be used like:

    scala> import cats.implicits._
    scala> fab.bifoldLeft(Option(0))((c, a) => c.map(_ + a.head), (c, b) => c.map(_ + b))
    res1: Option[Int] = Some(3)
    Definition Classes
    BinestedBifoldableBifoldable
  7. def bifoldMap[A, B, C](fab: Binested[F, G, H, A, B])(f: (A) ⇒ C, g: (B) ⇒ C)(implicit C: Monoid[C]): C

    Collapse the structure by mapping each element to an element of a type that has a cats.Monoid

    Collapse the structure by mapping each element to an element of a type that has a cats.Monoid

    Definition Classes
    Bifoldable
  8. def bifoldRight[A, B, C](fab: Binested[F, G, H, A, B], c: Eval[C])(f: (A, Eval[C]) ⇒ Eval[C], g: (B, Eval[C]) ⇒ Eval[C]): Eval[C]

    Collapse the structure with a right-associative function Right associative lazy bifold on F using the folding function 'f' and 'g'.

    Collapse the structure with a right-associative function Right associative lazy bifold on F using the folding function 'f' and 'g'.

    This method evaluates c lazily (in some cases it will not be needed), and returns a lazy value. We are using (_, Eval[C]) => Eval[C] to support laziness in a stack-safe way. Chained computation should be performed via .map and .flatMap.

    For more detailed information about how this method works see the documentation for Eval[_].

    Example:

    scala> import cats.Bifoldable
    scala> val fab = (List(1), 2)
    
    Folding by addition to zero:
    scala> val bifolded1 = Bifoldable[Tuple2].bifoldRight(fab, Eval.now(0))((a, c) => c.map(_ + a.head), (b, c) => c.map(_ + b))
    scala> bifolded1.value
    res0: Int = 3

    With syntax extensions, bifoldRight can be used like:

    scala> import cats.implicits._
    scala> val bifolded2 = fab.bifoldRight(Eval.now(0))((a, c) => c.map(_ + a.head), (b, c) => c.map(_ + b))
    scala> bifolded2.value
    res1: Int = 3
    Definition Classes
    BinestedBifoldableBifoldable
  9. def clone(): AnyRef
    Attributes
    protected[lang]
    Definition Classes
    AnyRef
    Annotations
    @throws( ... ) @native() @IntrinsicCandidate()
  10. def compose[G[_, _]](implicit ev: Bifoldable[G]): Bifoldable[[α, β]Binested[F, G, H, G[α, β], G[α, β]]]
    Definition Classes
    Bifoldable
  11. final def eq(arg0: AnyRef): Boolean
    Definition Classes
    AnyRef
  12. def equals(arg0: Any): Boolean
    Definition Classes
    AnyRef → Any
  13. final def getClass(): Class[_]
    Definition Classes
    AnyRef → Any
    Annotations
    @native() @IntrinsicCandidate()
  14. def hashCode(): Int
    Definition Classes
    AnyRef → Any
    Annotations
    @native() @IntrinsicCandidate()
  15. final def isInstanceOf[T0]: Boolean
    Definition Classes
    Any
  16. final def ne(arg0: AnyRef): Boolean
    Definition Classes
    AnyRef
  17. final def notify(): Unit
    Definition Classes
    AnyRef
    Annotations
    @native() @IntrinsicCandidate()
  18. final def notifyAll(): Unit
    Definition Classes
    AnyRef
    Annotations
    @native() @IntrinsicCandidate()
  19. final def synchronized[T0](arg0: ⇒ T0): T0
    Definition Classes
    AnyRef
  20. def toString(): String
    Definition Classes
    AnyRef → Any
  21. final def wait(arg0: Long, arg1: Int): Unit
    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  22. final def wait(arg0: Long): Unit
    Definition Classes
    AnyRef
    Annotations
    @throws( ... ) @native()
  23. final def wait(): Unit
    Definition Classes
    AnyRef
    Annotations
    @throws( ... )

Deprecated Value Members

  1. def finalize(): Unit
    Attributes
    protected[lang]
    Definition Classes
    AnyRef
    Annotations
    @throws( classOf[java.lang.Throwable] ) @Deprecated
    Deprecated

Inherited from Bifoldable[[δ$12$, ε$13$]Binested[F, G, H, δ$12$, ε$13$]]

Inherited from Serializable

Inherited from Serializable

Inherited from AnyRef

Inherited from Any

Ungrouped