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


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


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


observable val observable: Observable<out A>


ap fun <B> ap(fa: ObservableKOf<(A) -> B>): ObservableK<B>
bracketCase fun <B> bracketCase(use: (A) -> ObservableKOf<B>, release: (A, ExitCase<Throwable>) -> ObservableKOf<Unit>): ObservableK<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) -> 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 fun <A> async(fa: ObservableKProc<A>): ObservableK<A>
Creates a ObservableK that’ll run ObservableKProc.
asyncF fun <A> asyncF(fa: ObservableKProcF<A>): ObservableK<A>
cancelable fun <A> cancelable(fa: ((Either<Throwable, A>) -> Unit) -> CancelToken<ForObservableK>): ObservableK<A>
Creates a ObservableK that’ll run a cancelable operation.
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>

Extension Functions

ap fun <A, B> Kind<ForObservableK, A>.ap(arg1: Kind<ForObservableK, (A) -> B>): ObservableK<B>
as fun <A, B> Kind<ForObservableK, A>.as(arg1: B): ObservableK<B>
Replaces A inside F with B resulting in a Kind<F, B>
attempt fun <A> Kind<ForObservableK, A>.attempt(): ObservableK<Either<Throwable, A>>
bracket fun <A, B> Kind<ForObservableK, A>.bracket(arg1: (A) -> Kind<ForObservableK, Unit>, arg2: (A) -> Kind<ForObservableK, B>): ObservableK<B>
Meant for specifying tasks with safe resource acquisition and release in the face of errors and interruption. It would be the the equivalent of try/catch/finally statements in mainstream imperative languages for resource acquisition and release.
bracketCase fun <A, B> Kind<ForObservableK, A>.bracketCase(arg1: (A, ExitCase<Throwable>) -> Kind<ForObservableK, Unit>, arg2: (A) -> Kind<ForObservableK, B>): ObservableK<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.
combineAll fun <A> Kind<ForObservableK, A>.combineAll(arg1: Monoid<A>): A
continueOn fun <A> Kind<ForObservableK, A>.continueOn(arg1: CoroutineContext): ObservableK<A>
Continue the evaluation on provided CoroutineContext
effectM fun <A, B> Kind<ForObservableK, A>.effectM(arg1: (A) -> Kind<ForObservableK, B>): ObservableK<A>
effectMap fun <A, B> Kind<ForObservableK, A>.effectMap(arg1: suspend (A) -> B): ObservableK<B>
Helper function that provides an easy way to construct a suspend effect
ensure fun <A> Kind<ForObservableK, A>.ensure(arg1: () -> Throwable, arg2: (A) -> Boolean): ObservableK<A>
exists fun <A> Kind<ForObservableK, A>.exists(arg1: (A) -> Boolean): Boolean
filter fun <A> Kind<ForObservableK, A>.filter(arg1: (A) -> Boolean): ObservableK<A>
filterMap fun <A, B> Kind<ForObservableK, A>.filterMap(arg1: (A) -> Option<B>): ObservableK<B>
filterMap fun <A, B> Kind<ForObservableK, A>.filterMap(arg1: (A) -> Option<B>): ObservableK<B>
find fun <A> Kind<ForObservableK, A>.find(arg1: (A) -> Boolean): Option<A>
firstOption fun <A> Kind<ForObservableK, A>.firstOption(): Option<A>
fun <A> Kind<ForObservableK, A>.firstOption(arg1: (A) -> Boolean): Option<A>
fix fun <A> ObservableKOf<A>.fix(): ObservableK<A>
flatMap fun <A, B> Kind<ForObservableK, A>.flatMap(arg1: (A) -> Kind<ForObservableK, B>): ObservableK<B>
flatTap fun <A, B> Kind<ForObservableK, A>.flatTap(arg1: (A) -> Kind<ForObservableK, B>): ObservableK<A>
flatten fun <A> Kind<ForObservableK, Kind<ForObservableK, A>>.flatten(): ObservableK<A>
flattenOption fun <A> Kind<ForObservableK, Option<A>>.flattenOption(): ObservableK<A>
flatTraverse fun <G, A, B> Kind<ForObservableK, A>.flatTraverse(arg1: Monad<ForObservableK>, arg2: Applicative<G>, arg3: (A) -> Kind<G, Kind<ForObservableK, B>>): Kind<G, Kind<ForObservableK, B>>
fold fun <A> Kind<ForObservableK, A>.fold(arg1: Monoid<A>): A
foldLeft fun <A, B> Kind<ForObservableK, A>.foldLeft(arg1: B, arg2: (B, A) -> B): B
foldM fun <G, A, B> Kind<ForObservableK, A>.foldM(arg1: Monad<G>, arg2: B, arg3: (B, A) -> Kind<G, B>): Kind<G, B>
foldMap fun <A, B> Kind<ForObservableK, A>.foldMap(arg1: Monoid<B>, arg2: (A) -> B): B
foldMapM fun <G, A, B, MA : Monad<G>, MO : Monoid<B>> Kind<ForObservableK, A>.foldMapM(arg1: MA, arg2: MO, arg3: (A) -> Kind<G, B>): Kind<G, B>
foldRight fun <A, B> Kind<ForObservableK, A>.foldRight(arg1: Eval<B>, arg2: (A, Eval<B>) -> Eval<B>): Eval<B>
followedBy fun <A, B> Kind<ForObservableK, A>.followedBy(arg1: Kind<ForObservableK, B>): ObservableK<B>
followedByEval fun <A, B> Kind<ForObservableK, A>.followedByEval(arg1: Eval<Kind<ForObservableK, B>>): ObservableK<B>
forAll fun <A> Kind<ForObservableK, A>.forAll(arg1: (A) -> Boolean): Boolean
forEffect fun <A, B> Kind<ForObservableK, A>.forEffect(arg1: Kind<ForObservableK, B>): ObservableK<A>
forEffectEval fun <A, B> Kind<ForObservableK, A>.forEffectEval(arg1: Eval<Kind<ForObservableK, B>>): ObservableK<A>
fproduct fun <A, B> Kind<ForObservableK, A>.fproduct(arg1: (A) -> B): ObservableK<Tuple2<A, B>>
Applies f to an A inside F and returns the F structure with a tuple of the A value and the computed B value as result of applying f
get fun <A> Kind<ForObservableK, A>.get(arg1: Long): Option<A>
guarantee fun <A> Kind<ForObservableK, A>.guarantee(arg1: Kind<ForObservableK, Unit>): ObservableK<A>
Executes the given finalizer when the source is finished, either in success or in error, or if canceled.
guaranteeCase fun <A> Kind<ForObservableK, A>.guaranteeCase(arg1: (ExitCase<Throwable>) -> Kind<ForObservableK, Unit>): ObservableK<A>
Executes the given finalizer when the source is finished, either in success or in error, or if canceled, allowing for differentiating between exit conditions. That’s thanks to the ExitCase argument of the finalizer.
handleError fun <A> Kind<ForObservableK, A>.handleError(arg1: (Throwable) -> A): ObservableK<A>
handleErrorWith fun <A> Kind<ForObservableK, A>.handleErrorWith(arg1: (Throwable) -> Kind<ForObservableK, A>): ObservableK<A>
handleErrorWith fun <A> ObservableKOf<A>.handleErrorWith(function: (Throwable) -> ObservableKOf<A>): ObservableK<A>
ifM fun <B> Kind<ForObservableK, Boolean>.ifM(arg1: () -> Kind<ForObservableK, B>, arg2: () -> Kind<ForObservableK, B>): ObservableK<B>
imap fun <A, B> Kind<ForObservableK, A>.imap(arg1: (A) -> B, arg2: (B) -> A): ObservableK<B>
isEmpty fun <A> Kind<ForObservableK, A>.isEmpty(): Boolean
map fun <A, B> Kind<ForObservableK, A>.map(arg1: (A) -> B): ObservableK<B>
map fun <A, B> Kind<ForObservableK, A>.map(arg1: (A) -> B): ObservableK<B>
Transform the F wrapped value A into B preserving the F structure Kind<F, A> -> Kind<F, B>
map fun <A, B> Kind<ForObservableK, A>.map(arg1: (A) -> B): ObservableK<B>
map fun <A, B> Kind<ForObservableK, A>.map(arg1: (A) -> B): ObservableK<B>
mproduct fun <A, B> Kind<ForObservableK, A>.mproduct(arg1: (A) -> Kind<ForObservableK, B>): ObservableK<Tuple2<A, B>>
nonEmpty fun <A> Kind<ForObservableK, A>.nonEmpty(): Boolean
productL fun <A, B> Kind<ForObservableK, A>.productL(arg1: Kind<ForObservableK, B>): ObservableK<A>
productLEval fun <A, B> Kind<ForObservableK, A>.productLEval(arg1: Eval<Kind<ForObservableK, B>>): ObservableK<A>
redeem fun <A, B> Kind<ForObservableK, A>.redeem(arg1: (Throwable) -> B, arg2: (A) -> B): ObservableK<B>
redeemWith fun <A, B> Kind<ForObservableK, A>.redeemWith(arg1: (Throwable) -> Kind<ForObservableK, B>, arg2: (A) -> Kind<ForObservableK, B>): ObservableK<B>
reduceLeftOption fun <A> Kind<ForObservableK, A>.reduceLeftOption(arg1: (A, A) -> A): Option<A>
reduceLeftToOption fun <A, B> Kind<ForObservableK, A>.reduceLeftToOption(arg1: (A) -> B, arg2: (B, A) -> B): Option<B>
reduceRightOption fun <A> Kind<ForObservableK, A>.reduceRightOption(arg1: (A, Eval<A>) -> Eval<A>): Eval<Option<A>>
reduceRightToOption fun <A, B> Kind<ForObservableK, A>.reduceRightToOption(arg1: (A) -> B, arg2: (A, Eval<B>) -> Eval<B>): Eval<Option<B>>
rethrow fun <A> Kind<ForObservableK, Either<Throwable, A>>.rethrow(): ObservableK<A>
runAsync fun <A> Kind<ForObservableK, A>.runAsync(arg1: (Either<Throwable, A>) -> Kind<ForObservableK, Unit>): ObservableK<Unit>
runAsyncCancellable fun <A> Kind<ForObservableK, A>.runAsyncCancellable(arg1: (Either<Throwable, A>) -> Kind<ForObservableK, Unit>): ObservableK<() -> Unit>
select fun <A, B> Kind<ForObservableK, Either<A, B>>.select(arg1: Kind<ForObservableK, (A) -> B>): ObservableK<B>
selectM fun <A, B> Kind<ForObservableK, Either<A, B>>.selectM(arg1: Kind<ForObservableK, (A) -> B>): ObservableK<B>
sequence fun <G, A> Kind<ForObservableK, Kind<G, A>>.sequence(arg1: Applicative<G>): Kind<G, Kind<ForObservableK, A>>
sequence fun <A, G> ObservableKOf<Kind<G, A>>.sequence(GA: Applicative<G>): Kind<G, ObservableK<A>>
sequence_ fun <G, A> Kind<ForObservableK, Kind<G, A>>.sequence_(arg1: Applicative<G>): Kind<G, Unit>
size fun <A> Kind<ForObservableK, A>.size(arg1: Monoid<Long>): Long
traverse fun <G, A, B> Kind<ForObservableK, A>.traverse(arg1: Applicative<G>, arg2: (A) -> Kind<G, B>): Kind<G, Kind<ForObservableK, B>>
traverse_ fun <G, A, B> Kind<ForObservableK, A>.traverse_(arg1: Applicative<G>, arg2: (A) -> Kind<G, B>): Kind<G, Unit>
tupleLeft fun <A, B> Kind<ForObservableK, A>.tupleLeft(arg1: B): ObservableK<Tuple2<B, A>>
Pairs B with A returning a Kind<F, Tuple2<B, A>>
tupleRight fun <A, B> Kind<ForObservableK, A>.tupleRight(arg1: B): ObservableK<Tuple2<A, B>>
Pairs A with B returning a Kind<F, Tuple2<A, B>>
uncancelable fun <A> Kind<ForObservableK, A>.uncancelable(): ObservableK<A>
Meant for ensuring a given task continues execution even when interrupted.
unit fun <A> Kind<ForObservableK, A>.unit(): ObservableK<Unit>
Discards the A value inside F signaling this container may be pointing to a noop or an effect whose return value is deliberately ignored. The singleton value Unit serves as signal.
value fun <A> ObservableKOf<A>.value(): Observable<A>
widen fun <B, A : B> Kind<ForObservableK, A>.widen(): ObservableK<B>
Given A is a sub type of B, re-type this value from Kind<F, A> to Kind<F, B>

Companion Object Extension Functions

applicative fun ObservableK.Companion.applicative(): ObservableKApplicative
applicativeError fun ObservableK.Companion.applicativeError(): ObservableKApplicativeError
async fun ObservableK.Companion.async(): ObservableKAsync
bracket fun ObservableK.Companion.bracket(): ObservableKBracket
concurrent fun ObservableK.Companion.concurrent(dispatchers: Dispatchers<ForObservableK>): Concurrent<ForObservableK>
concurrentEffect fun ObservableK.Companion.concurrentEffect(): ObservableKConcurrentEffect
effect fun ObservableK.Companion.effect(): ObservableKEffect
foldable fun ObservableK.Companion.foldable(): ObservableKFoldable
functor fun ObservableK.Companion.functor(): ObservableKFunctor
functorFilter fun ObservableK.Companion.functorFilter(): ObservableKFunctorFilter
fx fun <A> ObservableK.Companion.fx(c: suspend AsyncSyntax<ForObservableK>.() -> A): ObservableK<A>
monad fun ObservableK.Companion.monad(): ObservableKMonad
monadConcat fun ObservableK.Companion.monadConcat(): ObservableKMonad
monadDefer fun ObservableK.Companion.monadDefer(): ObservableKMonadDefer
monadError fun ObservableK.Companion.monadError(): ObservableKMonadError
monadErrorConcat fun ObservableK.Companion.monadErrorConcat(): ObservableKMonadError
monadErrorFlat fun ObservableK.Companion.monadErrorFlat(): ObservableKMonadError
monadErrorSwitch fun ObservableK.Companion.monadErrorSwitch(): ObservableKMonadError
monadFilter fun ObservableK.Companion.monadFilter(): ObservableKMonadFilter
monadFlat fun ObservableK.Companion.monadFlat(): ObservableKMonad
monadSwitch fun ObservableK.Companion.monadSwitch(): ObservableKMonad
monadThrow fun ObservableK.Companion.monadThrow(): ObservableKMonadThrow
timer fun ObservableK.Companion.timer(): ObservableKTimer
traverse fun ObservableK.Companion.traverse(): ObservableKTraverse

Type Class Hierarchy