Skip to content
Fernando Cejas edited this page Dec 6, 2015 · 1 revision

@RxLogSubscriber Annotation

  • @RxLogSubscriber: Annotated classes which are of type rx.Subscriber will print the following debugging information when receiving items from an rx.Observable:
frodo_subscriber
@RxLogSubscriber
public class MySubscriberBackpressure extends Subscriber<Integer> {

    @Override
    public void onStart() {
        request(40);
    }

    @Override
    public void onNext(Integer value) {
        //empty
    }

    @Override
    public void onError(Throwable throwable) {
        //empty
    }

    @Override
    public void onCompleted() {
        if (!isUnsubscribed()) {
            unsubscribe();
        }
    }
}
Clone this wiki locally