https://kotlinlang.org logo
#rx
Title
# rx
u

ursus

05/31/2019, 4:40 PM
Copy code
DownloadManager {

   val eventsRelay = BehaviourRelay.create<Event>()
   val eventsObservable : Observable<Event>
   	get() = eventsRelay

	fun downloadSomething(params) {
		apiActuallyDownloadAndWriteObservable(params)
		    .doOnNext(eventsRelay)
			.subscribe {}
    }
}