object Invalid extends LeftProjection[Validated]
Extracts the Invalid (left/error) value, yielding nothing for Valid values.
Use Validated.Invalid[T] to get a typed Projection[Validated[T, Any], T].
- Alphabetic
- By Inheritance
- Invalid
- LeftProjection
- Projection
- StaticStage
- SAMStage
- Stagnation
- Evolution
- Stage
- Function1
- AnyRef
- Any
- Hide All
- Show All
- Public
- Protected
Value Members
- final def !=(arg0: Any): Boolean
- Definition Classes
- AnyRef → Any
- final def ##: Int
- Definition Classes
- AnyRef → Any
- final def ==(arg0: Any): Boolean
- Definition Classes
- AnyRef → Any
- def andThen[A](g: (Yield[Validated[Any, Any], Any, Nothing]) => A): (Validated[Any, Any]) => A
- Definition Classes
- Function1
- Annotations
- @unspecialized()
- final def apply[T]: Projection[Validated[T, Any], T]
Returns a typed view of this projection for left-side values of type
T.Returns a typed view of this projection for left-side values of type
T.The cast is safe because
Cis covariant in both parameters and the projection only reads (never writes) the container.- T
the concrete left-side type
- returns
this projection typed as
Projection[C[T, Any], T]
- Definition Classes
- LeftProjection
- final def apply(in: Validated[Any, Any]): Yield[Validated[Any, Any], Any, Nothing]
Processes
inand returns the Yield carrying the optional output, the status and the continuation.Processes
inand returns the Yield carrying the optional output, the status and the continuation.A stage that throws from here must have released its own resources first — see the Lifecycle section above.
- Definition Classes
- StaticStage → Stage → Function1
- final def asInstanceOf[T0]: T0
- Definition Classes
- Any
- def clone(): AnyRef
- Attributes
- protected[lang]
- Definition Classes
- AnyRef
- Annotations
- @throws(classOf[java.lang.CloneNotSupportedException]) @IntrinsicCandidate() @native()
- final def compose[_O, _E >: Nothing](that: Evolution[Any, _O, _E]): Evolution[Validated[Any, Any], _O, _E]
Composes this evolution with the one downstream of it, so that for every status
- def compose[A](g: (A) => Validated[Any, Any]): (A) => Yield[Validated[Any, Any], Any, Nothing]
- Definition Classes
- Function1
- Annotations
- @unspecialized()
- def dispose(): Unit
Releases everything held by the Stage that produced this evolution.
Releases everything held by the Stage that produced this evolution. That stage is permanently unusable afterwards — neither applied nor skipped again — and this is the only place its resources are released.
Whoever terminates a pipeline is responsible for disposing the evolution of the final Yield, so that the continuation is released at once instead of being carried around. The reference terminal driver is the
executeextension method ofh8io.stages.basein the lib module.dispose()stays valid after evolve has been called on the same instance, and must then release everything still alive, including whatever building the continuation acquired.evolvehands over no ownership: this evolution remains the cleanup point for its lineage until the continuation has run and produced an evolution of its own, which takes the role over from that moment.Exceptions are not part of this contract: a stage whose
applythrows produces no yield and therefore no evolution, so there is nothing to dispose — it must clean up after itself (see the Lifecycle section in Stage).A no-op is a fine implementation for a stage holding nothing external.
- Definition Classes
- Stagnation → Evolution
- final def eq(arg0: AnyRef): Boolean
- Definition Classes
- AnyRef
- def equals(arg0: AnyRef): Boolean
- Definition Classes
- AnyRef → Any
- final def evolve(status: Status[_]): Stage[Validated[Any, Any], Any, Nothing]
The next stage, for the given status.
The next stage, for the given status.
May release what belongs to this generation alone — anything the returned stage and its own evolution will not reuse.
evolveand dispose are not mutually exclusive. Usually only one of them is called on an instance: a terminal driver disposes, a continuing pipeline evolves and drops the previous evolution. But a caller may do both, and operators owning their inner stage (Loop,Repeatand the rest ofh8io.stages.cyclesin the lib module) do exactly that — they evolve eagerly and keep the innerdisposeas the cleanup handle of the generation they just built.- Definition Classes
- Stagnation → Evolution
- final def getClass(): Class[_ <: AnyRef]
- Definition Classes
- AnyRef → Any
- Annotations
- @IntrinsicCandidate() @native()
- def hashCode(): Int
- Definition Classes
- AnyRef → Any
- Annotations
- @IntrinsicCandidate() @native()
- final def isInstanceOf[T0]: Boolean
- Definition Classes
- Any
- final def map[_I, _O, _E](f: (Stage[Validated[Any, Any], Any, Nothing]) => Stage[_I, _O, _E]): Evolution[_I, _O, _E]
Applies
fto every stage this evolution would return, leaving disposal delegated to it unchanged.Applies
fto every stage this evolution would return, leaving disposal delegated to it unchanged.The way an operator keeps its wrapping in place across generations: the continuation comes back wrapped the same way the current stage is.
- Definition Classes
- Evolution
- Annotations
- @inline()
- final def ne(arg0: AnyRef): Boolean
- Definition Classes
- AnyRef
- val none: None[Nothing]
A pre-built
h8io.stages.Yield.Noneused when the container holds no value for this projection.A pre-built
h8io.stages.Yield.Noneused when the container holds no value for this projection.- Attributes
- protected
- Definition Classes
- Projection
- final def notify(): Unit
- Definition Classes
- AnyRef
- Annotations
- @IntrinsicCandidate() @native()
- final def notifyAll(): Unit
- Definition Classes
- AnyRef
- Annotations
- @IntrinsicCandidate() @native()
- def process(in: Validated[Any, Any]): StaticYield[Any, Nothing]
The processing logic for this stage.
The processing logic for this stage.
- in
the input value
- returns
a h8io.stages.base.StaticYield describing whether an output was produced and the resulting
h8io.stages.Status
- Definition Classes
- Invalid → StaticStage
- final def skip(): Evolution[Validated[Any, Any], Any, Nothing]
Returns this stage's Evolution without consuming an input.
Returns this stage's Evolution without consuming an input.
Called instead of
applywhenever the stage takes part in a run but has nothing to process: the upstream yielded no output, or a binary operator excluded this branch. The evolution must be the one the stage would have returned had it run. Likeapply,skip()may perform side effects — a decorator, for instance, may advance or release the inner stage it owns. - def some(out: Any): Some[Any, Nothing]
Creates a successful
h8io.stages.Yield.Somecarryingout.Creates a successful
h8io.stages.Yield.Somecarryingout.- Attributes
- protected
- Definition Classes
- Projection
- final def synchronized[T0](arg0: => T0): T0
- Definition Classes
- AnyRef
- def toString(): String
- Definition Classes
- Function1 → AnyRef → Any
- final def wait(arg0: Long, arg1: Int): Unit
- Definition Classes
- AnyRef
- Annotations
- @throws(classOf[java.lang.InterruptedException])
- final def wait(arg0: Long): Unit
- Definition Classes
- AnyRef
- Annotations
- @throws(classOf[java.lang.InterruptedException]) @native()
- final def wait(): Unit
- Definition Classes
- AnyRef
- Annotations
- @throws(classOf[java.lang.InterruptedException])
- final def ~>[_O, _E >: Nothing](that: Stage[Any, _O, _E]): Stage[Validated[Any, Any], _O, _E]
Composes this stage with
that, feeding this stage's output into it.Composes this stage with
that, feeding this stage's output into it. See the Composition section above for what happens when there is no output to feed.- Definition Classes
- Stage
- Annotations
- @inline()
Deprecated Value Members
- def finalize(): Unit
- Attributes
- protected[lang]
- Definition Classes
- AnyRef
- Annotations
- @throws(classOf[java.lang.Throwable]) @Deprecated
- Deprecated
(Since version 9)