.class public final Lio/reactivex/internal/subscribers/LambdaSubscriber; .super Ljava/util/concurrent/atomic/AtomicReference; .source "LambdaSubscriber.java" # interfaces .implements Lorg/reactivestreams/Subscriber; .implements Lorg/reactivestreams/Subscription; .implements Lio/reactivex/disposables/Disposable; # annotations .annotation system Ldalvik/annotation/Signature; value = { "", "Ljava/util/concurrent/atomic/AtomicReference<", "Lorg/reactivestreams/Subscription;", ">;", "Lorg/reactivestreams/Subscriber<", "TT;>;", "Lorg/reactivestreams/Subscription;", "Lio/reactivex/disposables/Disposable;" } .end annotation # static fields .field private static final serialVersionUID:J = -0x64a12a8486b15cccL # instance fields .field final onComplete:Lio/reactivex/functions/Action; .field final onError:Lio/reactivex/functions/Consumer; .annotation system Ldalvik/annotation/Signature; value = { "Lio/reactivex/functions/Consumer<", "-", "Ljava/lang/Throwable;", ">;" } .end annotation .end field .field final onNext:Lio/reactivex/functions/Consumer; .annotation system Ldalvik/annotation/Signature; value = { "Lio/reactivex/functions/Consumer<", "-TT;>;" } .end annotation .end field .field final onSubscribe:Lio/reactivex/functions/Consumer; .annotation system Ldalvik/annotation/Signature; value = { "Lio/reactivex/functions/Consumer<", "-", "Lorg/reactivestreams/Subscription;", ">;" } .end annotation .end field # direct methods .method public constructor (Lio/reactivex/functions/Consumer;Lio/reactivex/functions/Consumer;Lio/reactivex/functions/Action;Lio/reactivex/functions/Consumer;)V .locals 0 .annotation system Ldalvik/annotation/Signature; value = { "(", "Lio/reactivex/functions/Consumer<", "-TT;>;", "Lio/reactivex/functions/Consumer<", "-", "Ljava/lang/Throwable;", ">;", "Lio/reactivex/functions/Action;", "Lio/reactivex/functions/Consumer<", "-", "Lorg/reactivestreams/Subscription;", ">;)V" } .end annotation .line 37 invoke-direct {p0}, Ljava/util/concurrent/atomic/AtomicReference;->()V .line 38 iput-object p1, p0, Lio/reactivex/internal/subscribers/LambdaSubscriber;->onNext:Lio/reactivex/functions/Consumer; .line 39 iput-object p2, p0, Lio/reactivex/internal/subscribers/LambdaSubscriber;->onError:Lio/reactivex/functions/Consumer; .line 40 iput-object p3, p0, Lio/reactivex/internal/subscribers/LambdaSubscriber;->onComplete:Lio/reactivex/functions/Action; .line 41 iput-object p4, p0, Lio/reactivex/internal/subscribers/LambdaSubscriber;->onSubscribe:Lio/reactivex/functions/Consumer; return-void .end method # virtual methods .method public cancel()V .locals 0 .line 115 invoke-static {p0}, Lio/reactivex/internal/subscriptions/SubscriptionHelper;->cancel(Ljava/util/concurrent/atomic/AtomicReference;)Z return-void .end method .method public dispose()V .locals 0 .line 100 invoke-virtual {p0}, Lio/reactivex/internal/subscribers/LambdaSubscriber;->cancel()V return-void .end method .method public isDisposed()Z .locals 2 .line 105 invoke-virtual {p0}, Lio/reactivex/internal/subscribers/LambdaSubscriber;->get()Ljava/lang/Object; move-result-object v0 sget-object v1, Lio/reactivex/internal/subscriptions/SubscriptionHelper;->CANCELLED:Lio/reactivex/internal/subscriptions/SubscriptionHelper; if-ne v0, v1, :cond_0 const/4 v0, 0x1 goto :goto_0 :cond_0 const/4 v0, 0x0 :goto_0 return v0 .end method .method public onComplete()V .locals 2 .line 87 invoke-virtual {p0}, Lio/reactivex/internal/subscribers/LambdaSubscriber;->get()Ljava/lang/Object; move-result-object v0 sget-object v1, Lio/reactivex/internal/subscriptions/SubscriptionHelper;->CANCELLED:Lio/reactivex/internal/subscriptions/SubscriptionHelper; if-eq v0, v1, :cond_0 .line 88 sget-object v0, Lio/reactivex/internal/subscriptions/SubscriptionHelper;->CANCELLED:Lio/reactivex/internal/subscriptions/SubscriptionHelper; invoke-virtual {p0, v0}, Lio/reactivex/internal/subscribers/LambdaSubscriber;->lazySet(Ljava/lang/Object;)V .line 90 :try_start_0 iget-object v0, p0, Lio/reactivex/internal/subscribers/LambdaSubscriber;->onComplete:Lio/reactivex/functions/Action; invoke-interface {v0}, Lio/reactivex/functions/Action;->run()V :try_end_0 .catch Ljava/lang/Throwable; {:try_start_0 .. :try_end_0} :catch_0 goto :goto_0 :catch_0 move-exception v0 .line 92 invoke-static {v0}, Lio/reactivex/exceptions/Exceptions;->throwIfFatal(Ljava/lang/Throwable;)V .line 93 invoke-static {v0}, Lio/reactivex/plugins/RxJavaPlugins;->onError(Ljava/lang/Throwable;)V :cond_0 :goto_0 return-void .end method .method public onError(Ljava/lang/Throwable;)V .locals 4 .line 72 invoke-virtual {p0}, Lio/reactivex/internal/subscribers/LambdaSubscriber;->get()Ljava/lang/Object; move-result-object v0 sget-object v1, Lio/reactivex/internal/subscriptions/SubscriptionHelper;->CANCELLED:Lio/reactivex/internal/subscriptions/SubscriptionHelper; if-eq v0, v1, :cond_0 .line 73 sget-object v0, Lio/reactivex/internal/subscriptions/SubscriptionHelper;->CANCELLED:Lio/reactivex/internal/subscriptions/SubscriptionHelper; invoke-virtual {p0, v0}, Lio/reactivex/internal/subscribers/LambdaSubscriber;->lazySet(Ljava/lang/Object;)V .line 75 :try_start_0 iget-object v0, p0, Lio/reactivex/internal/subscribers/LambdaSubscriber;->onError:Lio/reactivex/functions/Consumer; invoke-interface {v0, p1}, Lio/reactivex/functions/Consumer;->accept(Ljava/lang/Object;)V :try_end_0 .catch Ljava/lang/Throwable; {:try_start_0 .. :try_end_0} :catch_0 goto :goto_0 :catch_0 move-exception v0 .line 77 invoke-static {v0}, Lio/reactivex/exceptions/Exceptions;->throwIfFatal(Ljava/lang/Throwable;)V .line 78 new-instance v1, Lio/reactivex/exceptions/CompositeException; const/4 v2, 0x2 new-array v2, v2, [Ljava/lang/Throwable; const/4 v3, 0x0 aput-object p1, v2, v3 const/4 p1, 0x1 aput-object v0, v2, p1 invoke-direct {v1, v2}, Lio/reactivex/exceptions/CompositeException;->([Ljava/lang/Throwable;)V invoke-static {v1}, Lio/reactivex/plugins/RxJavaPlugins;->onError(Ljava/lang/Throwable;)V goto :goto_0 .line 81 :cond_0 invoke-static {p1}, Lio/reactivex/plugins/RxJavaPlugins;->onError(Ljava/lang/Throwable;)V :goto_0 return-void .end method .method public onNext(Ljava/lang/Object;)V .locals 1 .annotation system Ldalvik/annotation/Signature; value = { "(TT;)V" } .end annotation .line 59 invoke-virtual {p0}, Lio/reactivex/internal/subscribers/LambdaSubscriber;->isDisposed()Z move-result v0 if-nez v0, :cond_0 .line 61 :try_start_0 iget-object v0, p0, Lio/reactivex/internal/subscribers/LambdaSubscriber;->onNext:Lio/reactivex/functions/Consumer; invoke-interface {v0, p1}, Lio/reactivex/functions/Consumer;->accept(Ljava/lang/Object;)V :try_end_0 .catch Ljava/lang/Throwable; {:try_start_0 .. :try_end_0} :catch_0 goto :goto_0 :catch_0 move-exception p1 .line 63 invoke-static {p1}, Lio/reactivex/exceptions/Exceptions;->throwIfFatal(Ljava/lang/Throwable;)V .line 64 invoke-virtual {p0}, Lio/reactivex/internal/subscribers/LambdaSubscriber;->get()Ljava/lang/Object; move-result-object v0 check-cast v0, Lorg/reactivestreams/Subscription; invoke-interface {v0}, Lorg/reactivestreams/Subscription;->cancel()V .line 65 invoke-virtual {p0, p1}, Lio/reactivex/internal/subscribers/LambdaSubscriber;->onError(Ljava/lang/Throwable;)V :cond_0 :goto_0 return-void .end method .method public onSubscribe(Lorg/reactivestreams/Subscription;)V .locals 1 .line 46 invoke-static {p0, p1}, Lio/reactivex/internal/subscriptions/SubscriptionHelper;->setOnce(Ljava/util/concurrent/atomic/AtomicReference;Lorg/reactivestreams/Subscription;)Z move-result v0 if-eqz v0, :cond_0 .line 48 :try_start_0 iget-object v0, p0, Lio/reactivex/internal/subscribers/LambdaSubscriber;->onSubscribe:Lio/reactivex/functions/Consumer; invoke-interface {v0, p0}, Lio/reactivex/functions/Consumer;->accept(Ljava/lang/Object;)V :try_end_0 .catch Ljava/lang/Throwable; {:try_start_0 .. :try_end_0} :catch_0 goto :goto_0 :catch_0 move-exception v0 .line 50 invoke-static {v0}, Lio/reactivex/exceptions/Exceptions;->throwIfFatal(Ljava/lang/Throwable;)V .line 51 invoke-interface {p1}, Lorg/reactivestreams/Subscription;->cancel()V .line 52 invoke-virtual {p0, v0}, Lio/reactivex/internal/subscribers/LambdaSubscriber;->onError(Ljava/lang/Throwable;)V :cond_0 :goto_0 return-void .end method .method public request(J)V .locals 1 .line 110 invoke-virtual {p0}, Lio/reactivex/internal/subscribers/LambdaSubscriber;->get()Ljava/lang/Object; move-result-object v0 check-cast v0, Lorg/reactivestreams/Subscription; invoke-interface {v0, p1, p2}, Lorg/reactivestreams/Subscription;->request(J)V return-void .end method