open static fun <T : Any> toHandler(observer: Observer<T>): Handler<T>
Adapt a Subscriber as a Handler<T>;. When the event handler completes, the observer will complete immediatly after the event is received, as a single event is expected.
observer - the subscriber to adapt
Return
a Handler<T>
open static fun <T : Any> toHandler(observer: Observer<T>, multi: Boolean): Handler<T>
Adapt a Subscriber as a Handler<T>;. When parameter is false and the event handler completes, the observer will complete immediatly after the event is received, as a single event is expected.
observer - the subscriber to adapt
multi - true if the handler can emit multiple events
Return
a Handler<T>
open static fun <T : Any> toHandler(onNext: Action1<T>): Handler<T>
Adapt an item callback as a Handler<T>.
onNext - the Action1<T> you have designed to accept the resolution from the Handler<T>
Return
a Handler<T>