{
 log("onNext: " + integer);
 }
 }, new Consumer<Throwable>() {
 @Override
 public void accept(Throwable throwable) throws Exception {
 log("onError" + throwable);
 }
 }, new Action() {
 @Override
 public void run() throws Exception {
 log("onComplete!");
 }
 }); Java