Packages

  • package root
    Definition Classes
    root
  • package h8io
    Definition Classes
    root
  • package stages
    Definition Classes
    h8io
  • package base

    Type aliases used throughout the lib module for describing stage transformations.

    Type aliases used throughout the lib module for describing stage transformations.

    // A decorator is a stage itself: it wraps a Stage[I, O, E] and is one:
    val myDecorator: Decorator[String, Int, Nothing] = CompleteIfNone(stage)
    
    // A decoration is the function building it; an alteration is the same with the types free to change:
    val myDecoration: Decoration[String, Int, Nothing] = CompleteIfNone(_)
    val myAlteration: Alteration[Stage[String, Int, Nothing], Stage[String, Option[Int], Nothing]] = Lift(_)
    Definition Classes
    stages
  • package cats
    Definition Classes
    stages
  • package cycles
    Definition Classes
    stages
  • package operators
    Definition Classes
    stages
  • package projections
    Definition Classes
    stages
  • package std
    Definition Classes
    stages
  • Evolution
  • Stage
  • Status
  • Yield

sealed trait Yield[-I, +O, +E] extends AnyRef

What a Stage returns for one input: an optional output, the Status of that run, and the Evolution that picks the stage handling the next one.

Yield is the internal value flowing from stage to stage, not the answer the pipeline gives to the outside world — that is h8io.stages.base.Outcome in the lib module, produced once someone terminates the pipeline.

There are two variants, Yield.Some and Yield.None, according to whether an output was produced. Match on them when the two cases are handled differently, on Yield itself when they are not.

I

the input type of the stages held by the evolution (contravariant)

O

the output type (covariant)

E

the error type (covariant)

Linear Supertypes
AnyRef, Any
Known Subclasses
Ordering
  1. Alphabetic
  2. By Inheritance
Inherited
  1. Yield
  2. AnyRef
  3. Any
  1. Hide All
  2. Show All
Visibility
  1. Public
  2. All

Abstract Value Members

  1. abstract val evolution: Evolution[I, O, E]

    The continuation: which stage handles the next input, given status.

  2. abstract def map[_I, _O, _E](mapOut: (O) ⇒ _O, mapStatus: (Status[E]) ⇒ Status[_E], mapEvolution: (Evolution[I, O, E]) ⇒ Evolution[_I, _O, _E]): Yield[_I, _O, _E]

    Transforms all three components at once.

    Transforms all three components at once. mapOut is not called on a Yield.None, which has no output to transform, but is still required so that the result type is the same for both variants.

  3. abstract def outOption: Option[O]

    The output as an Option — for when only its presence matters.

    The output as an Option — for when only its presence matters. Prefer matching on Yield.Some / Yield.None when the status or the evolution is needed too.

  4. abstract val status: Status[E]

    The status of the run that produced this yield.

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 clone(): AnyRef
    Attributes
    protected[lang]
    Definition Classes
    AnyRef
    Annotations
    @throws( ... ) @native() @IntrinsicCandidate()
  6. final def eq(arg0: AnyRef): Boolean
    Definition Classes
    AnyRef
  7. def equals(arg0: Any): Boolean
    Definition Classes
    AnyRef → Any
  8. def evolve(): Stage[I, O, E]

    The stage that handles the next input: the continuation this yield's own status selects.

    The stage that handles the next input: the continuation this yield's own status selects.

    Going through the evolution directly is the exception, not the rule — the status a yield carries is the one its continuation must be chosen by, and this method is what pairs them.

  9. final def getClass(): Class[_]
    Definition Classes
    AnyRef → Any
    Annotations
    @native() @IntrinsicCandidate()
  10. def hashCode(): Int
    Definition Classes
    AnyRef → Any
    Annotations
    @native() @IntrinsicCandidate()
  11. final def isInstanceOf[T0]: Boolean
    Definition Classes
    Any
  12. final def ne(arg0: AnyRef): Boolean
    Definition Classes
    AnyRef
  13. final def notify(): Unit
    Definition Classes
    AnyRef
    Annotations
    @native() @IntrinsicCandidate()
  14. final def notifyAll(): Unit
    Definition Classes
    AnyRef
    Annotations
    @native() @IntrinsicCandidate()
  15. final def synchronized[T0](arg0: ⇒ T0): T0
    Definition Classes
    AnyRef
  16. def toString(): String
    Definition Classes
    AnyRef → Any
  17. final def wait(arg0: Long, arg1: Int): Unit
    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  18. final def wait(arg0: Long): Unit
    Definition Classes
    AnyRef
    Annotations
    @throws( ... ) @native()
  19. 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 AnyRef

Inherited from Any

Ungrouped