我怎么能用RxJava在next()上抛出错误
.subscribe(
new Action1<Response>() {
@Override
public void call(Response response) {
if (response.isSuccess())
//handle success
else
//throw an Throwable(reponse.getMessage())
}
},
new Action1<Throwable>() {
@Override
public void call(Throwable throwable) {
//handle Throwable throw from onNext();
}
}
);
我不想处理.我怎样才能把它扔到一起,并与其他可扔的东西一起处理?(!response.isSuccess())
onNext()
onError()