arrow-effects-rx2-data / arrow.effects.rx2 / FlowableK


@higherkind data class FlowableK<A> : FlowableKOf<A>, FlowableKKindedJ<A>


<init> FlowableK(flowable: Flowable<A>)


flowable val flowable: Flowable<A>


ap fun <B> ap(fa: FlowableKOf<(A) -> B>): FlowableK<B>
bracketCase fun <B> bracketCase(use: (A) -> FlowableKOf<B>, release: (A, ExitCase<Throwable>) -> FlowableKOf<Unit>, mode: BackpressureStrategy = BackpressureStrategy.BUFFER): FlowableK<B>
A way to safely acquire a resource and release in the face of errors and cancellation. It uses ExitCase to distinguish between different exit cases when releasing the acquired resource.
concatMap fun <B> concatMap(f: (A) -> FlowableKOf<B>): FlowableK<B>
continueOn fun continueOn(ctx: CoroutineContext): FlowableK<A>
equals fun equals(other: Any?): Boolean
flatMap fun <B> flatMap(f: (A) -> FlowableKOf<B>): FlowableK<B>
foldLeft fun <B> foldLeft(b: B, f: (B, A) -> B): B
foldRight fun <B> foldRight(lb: Eval<B>, f: (A, Eval<B>) -> Eval<B>): Eval<B>
handleErrorWith fun handleErrorWith(function: (Throwable) -> FlowableKOf<A>): FlowableK<A>
hashCode fun hashCode(): Int
map fun <B> map(f: (A) -> B): FlowableK<B>
runAsync fun runAsync(cb: (Either<Throwable, A>) -> FlowableKOf<Unit>): FlowableK<Unit>
runAsyncCancellable fun runAsyncCancellable(cb: (Either<Throwable, A>) -> FlowableKOf<Unit>): FlowableK<Disposable>
switchMap fun <B> switchMap(f: (A) -> FlowableKOf<B>): FlowableK<B>
traverse fun <G, B> traverse(GA: Applicative<G>, f: (A) -> Kind<G, B>): Kind<G, FlowableK<B>>

Companion Object Functions

async fun <A> async(fa: FlowableKProc<A>, mode: BackpressureStrategy = BackpressureStrategy.BUFFER): FlowableK<A>
Creates a FlowableK that’ll run FlowableKProc.
asyncF fun <A> asyncF(fa: FlowableKProcF<A>, mode: BackpressureStrategy = BackpressureStrategy.BUFFER): FlowableK<A>
defer fun <A> defer(fa: () -> FlowableKOf<A>): FlowableK<A>
invoke operator fun <A> invoke(fa: () -> A): FlowableK<A>
just fun <A> just(a: A): FlowableK<A>
raiseError fun <A> raiseError(t: Throwable): FlowableK<A>
tailRecM tailrec fun <A, B> tailRecM(a: A, f: (A) -> FlowableKOf<Either<A, B>>): FlowableK<B>

Extension Functions

unsafeRunAsync fun <A> SingleKOf<A>.unsafeRunAsync(cb: (Either<Throwable, A>) -> Unit): Unit
Runs the SingleK asynchronously and then runs the cb. Catches all errors that may be thrown in await. Errors from cb will still throw as expected.
unsafeRunSync fun <A> SingleKOf<A>.unsafeRunSync(): A
Runs this SingleK with Single.blockingGet. Does not handle errors at all, rethrowing them if they happen.