June 2018
Intermediate to advanced
280 pages
7h 46m
English
Creating Observables from scratch can be done by calling one of the following io.reactivex.Observable methods (operators):
The following example shows how to construct an Observable from scratch. Call onNext() until the observer is not disposed, onComplete() and onError() programmatically in order to get a 1 to 4 range of numbers:

As we can see in the preceding screenshot, the output is as expected, range from 1 to 4, and the sequence gets disposed of after usage.
Read now
Unlock full access