RxJava

RxJava – Reactive Extensions for the JVM – a library for composing asynchronous and event-based programs using observable sequences for the Java VM.

rxjava gradle dependency

compile 'io.reactivex.rxjava2:rxjava:2.2.11'

rxjava example for Android