Skip to content

Instantly share code, notes, and snippets.

Embed
What would you like to do?
Observable.just("a","b","c","d","e","f","g","h","i","j")
.subscribe(new Observer<String>() {
@Override
public void onSubscribe(Disposable disposable) {
log.info("onSubscribe");
}
@Override
public void onNext(String s) {
log.info("onNext -> {}",s);
}
@Override
public void onError(Throwable throwable) {
log.info("onError {}",throwable.getMessage());
}
@Override
public void onComplete() {
log.info("onComplete");
}
});
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment