Search

arrow-fx-rx2 / arrow.fx.rx2 / ObservableK

ObservableK

data class ObservableK<out A> : ObservableKOf<A>

Constructors

<init> ObservableK(observable: Observable<out A>)

Properties

observable val observable: Observable<out A>

Functions

ap fun <B> ap(fa: ObservableKOf<(A) -> B>): ObservableK<B>
bracketCase 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.fun <B> bracketCase(use: (A) -> ObservableKOf<B>, release: (A, ExitCase<Throwable>) -> ObservableKOf<Unit>): ObservableK<B>
concatMap fun <B> concatMap(f: (A) -> ObservableKOf<B>): ObservableK<B>
continueOn fun continueOn(ctx: CoroutineContext): ObservableK<A>
equals fun equals(other: Any?): Boolean
filterMap fun <B> filterMap(f: (A) -> Option<B>): ObservableK<B>
flatMap fun <B> flatMap(f: (A) -> ObservableKOf<B>): ObservableK<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>
hashCode fun hashCode(): Int
map fun <B> map(f: (A) -> B): ObservableK<B>
runAsync fun runAsync(cb: (Either<Throwable, A>) -> ObservableKOf<Unit>): ObservableK<Unit>
runAsyncCancellable fun runAsyncCancellable(cb: (Either<Throwable, A>) -> ObservableKOf<Unit>): ObservableK<Disposable>
switchMap fun <B> switchMap(f: (A) -> ObservableKOf<B>): ObservableK<B>
traverse fun <G, B> traverse(GA: Applicative<G>, f: (A) -> Kind<G, B>): Kind<G, ObservableK<B>>

Companion Object Functions

async Creates a ObservableK that’ll run ObservableKProc.fun <A> async(fa: ObservableKProc<A>): ObservableK<A>
asyncF fun <A> asyncF(fa: ObservableKProcF<A>): ObservableK<A>
cancelable Creates a ObservableK that’ll run a cancelable operation.fun <A> cancelable(fa: ((Either<Throwable, A>) -> Unit) -> CancelToken<ForObservableK>): ObservableK<A>
cancelableF fun <A> cancelableF(fa: ((Either<Throwable, A>) -> Unit) -> ObservableKOf<CancelToken<ForObservableK>>): ObservableK<A>
defer fun <A> defer(fa: () -> ObservableKOf<A>): ObservableK<A>
invoke operator fun <A> invoke(fa: () -> A): ObservableK<A>
just fun <A> just(a: A): ObservableK<A>
raiseError fun <A> raiseError(t: Throwable): ObservableK<A>
tailRecM tailrec fun <A, B> tailRecM(a: A, f: (A) -> ObservableKOf<Either<A, B>>): ObservableK<B>

Companion Object Extension Functions

concurrent fun ObservableK.Companion.concurrent(dispatchers: Dispatchers<ForObservableK> = ObservableK.dispatchers()): Concurrent<ForObservableK>
fx fun <A> ObservableK.Companion.fx(c: suspend ConcurrentSyntax<ForObservableK>.() -> A): ObservableK<A>
monadConcat fun ObservableK.Companion.monadConcat(): ObservableKMonad
monadErrorConcat fun ObservableK.Companion.monadErrorConcat(): ObservableKMonadError
monadErrorFlat fun ObservableK.Companion.monadErrorFlat(): ObservableKMonadError
monadErrorSwitch fun ObservableK.Companion.monadErrorSwitch(): ObservableKMonadError
monadFlat fun ObservableK.Companion.monadFlat(): ObservableKMonad
monadSwitch fun ObservableK.Companion.monadSwitch(): ObservableKMonad