You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
jianglk.darker
7ee447c011
|
4 months ago | |
---|---|---|
.. | ||
api | 4 months ago | |
src | 4 months ago | |
test | 4 months ago | |
README.md | 4 months ago | |
build.gradle | 4 months ago | |
package.list | 4 months ago |
README.md
Module kotlinx-coroutines-rx3
Utilities for RxJava 3.x.
Coroutine builders:
Name | Result | Scope | Description |
---|---|---|---|
rxCompletable | Completable |
CoroutineScope | Cold completable that starts coroutine on subscribe |
rxMaybe | Maybe |
CoroutineScope | Cold maybe that starts coroutine on subscribe |
rxSingle | Single |
CoroutineScope | Cold single that starts coroutine on subscribe |
rxObservable | Observable |
ProducerScope | Cold observable that starts coroutine on subscribe |
rxFlowable | Flowable |
ProducerScope | Cold observable that starts coroutine on subscribe with backpressure support |
Integration with Flow:
Name | Result | Description |
---|---|---|
Flow.asFlowable | Flowable |
Converts the given flow to a cold Flowable. |
Flow.asObservable | Observable |
Converts the given flow to a cold Observable. |
ObservableSource.asFlow | Flow |
Converts the given cold ObservableSource to flow |
Suspending extension functions and suspending iteration:
Name | Description |
---|---|
CompletableSource.await | Awaits for completion of the completable value |
MaybeSource.await | Awaits for the value of the maybe and returns it or null |
MaybeSource.awaitOrDefault | Awaits for the value of the maybe and returns it or default |
SingleSource.await | Awaits for completion of the single value and returns it |
ObservableSource.awaitFirst | Awaits for the first value from the given observable |
ObservableSource.awaitFirstOrDefault | Awaits for the first value from the given observable or default |
ObservableSource.awaitFirstOrElse | Awaits for the first value from the given observable or default from a function |
ObservableSource.awaitFirstOrNull | Awaits for the first value from the given observable or null |
ObservableSource.awaitLast | Awaits for the last value from the given observable |
ObservableSource.awaitSingle | Awaits for the single value from the given observable |
Note that Flowable
is a subclass of Reactive Streams
Publisher
and extensions for it are covered by
kotlinx-coroutines-reactive module.
Conversion functions:
Name | Description |
---|---|
Job.asCompletable | Converts job to hot completable |
Deferred.asSingle | Converts deferred value to hot single |
Scheduler.asCoroutineDispatcher | Converts scheduler to CoroutineDispatcher |
Package kotlinx.coroutines.rx3
Utilities for RxJava 3.x.