arrow-fx / arrow.fx.typeclasses / Fiber
interface ~~Fiber~~<F, out A> : FiberOf<F, A>
Deprecated: The IO datatype and it’s related type classes will disappear in Arrow 0.13.0. All useful operations are offered directly over suspend functions by Arrow Fx Coroutines. https://arrow-kt.io/docs/fx/async/
Fiber represents the pure result of an Async data type being started concurrently and that can be either joined or cancelled.
You can think of fibers as being lightweight threads, a Fiber being a concurrency primitive for doing cooperative multi-tasking.
| cancel | Triggers the cancellation of the Fiber.abstract fun cancel(): CancelToken<F> |
| component1 | open operator fun component1(): Kind<F, A> |
| component2 | open operator fun component2(): CancelToken<F> |
| join | Returns a new task that will await for the completion of the underlying Fiber, (asynchronously) blocking the current run-loop until that result is available.abstract fun join(): Kind<F, A> |
| invoke | Fiber constructor.operator fun <F, A> invoke(join: Kind<F, A>, cancel: CancelToken<F>): Fiber<F, A> |
| applicative | fun <F> Fiber.Companion.~~applicative~~(C: Concurrent<F>): Applicative<Kind<ForFiber, F>> |
| apply | fun <F> Fiber.Companion.~~apply~~(C: Concurrent<F>): Apply<Kind<ForFiber, F>> |
| functor | fun <F> Fiber.Companion.~~functor~~(C: Concurrent<F>): Functor<Kind<ForFiber, F>> |
| monoid | fun <F, A> Fiber.Companion.~~monoid~~(C: Concurrent<F>, M: Monoid<A>): Monoid<Fiber<F, A>> |
| semigroup | fun <F, A> Fiber.Companion.~~semigroup~~(C: Concurrent<F>, S: Semigroup<A>): Semigroup<Fiber<F, A>> |
Do you like Arrow?
✖