.class public final Lk0/i0/a/b; .super Ljava/util/concurrent/atomic/AtomicInteger; .source "CallArbiter.java" # interfaces .implements Lrx/Subscription; .implements Lrx/Producer; # annotations .annotation system Ldalvik/annotation/Signature; value = { "", "Ljava/util/concurrent/atomic/AtomicInteger;", "Lrx/Subscription;", "Lrx/Producer;" } .end annotation # instance fields .field public final call:Lk0/d; .annotation system Ldalvik/annotation/Signature; value = { "Lk0/d<", "TT;>;" } .end annotation .end field .field public volatile response:Lk0/b0; .annotation system Ldalvik/annotation/Signature; value = { "Lk0/b0<", "TT;>;" } .end annotation .end field .field public final subscriber:Lrx/Subscriber; .annotation system Ldalvik/annotation/Signature; value = { "Lrx/Subscriber<", "-", "Lk0/b0<", "TT;>;>;" } .end annotation .end field .field public volatile unsubscribed:Z # direct methods .method public constructor (Lk0/d;Lrx/Subscriber;)V .locals 1 .annotation system Ldalvik/annotation/Signature; value = { "(", "Lk0/d<", "TT;>;", "Lrx/Subscriber<", "-", "Lk0/b0<", "TT;>;>;)V" } .end annotation const/4 v0, 0x0 invoke-direct {p0, v0}, Ljava/util/concurrent/atomic/AtomicInteger;->(I)V iput-object p1, p0, Lk0/i0/a/b;->call:Lk0/d; iput-object p2, p0, Lk0/i0/a/b;->subscriber:Lrx/Subscriber; return-void .end method # virtual methods .method public final a(Lk0/b0;)V .locals 5 .annotation system Ldalvik/annotation/Signature; value = { "(", "Lk0/b0<", "TT;>;)V" } .end annotation const/4 v0, 0x0 :try_start_0 iget-boolean v1, p0, Lk0/i0/a/b;->unsubscribed:Z if-nez v1, :cond_0 iget-object v1, p0, Lk0/i0/a/b;->subscriber:Lrx/Subscriber; invoke-interface {v1, p1}, Ll0/g;->onNext(Ljava/lang/Object;)V :try_end_0 .catch Lrx/exceptions/OnCompletedFailedException; {:try_start_0 .. :try_end_0} :catch_2 .catch Lrx/exceptions/OnErrorFailedException; {:try_start_0 .. :try_end_0} :catch_2 .catch Lrx/exceptions/OnErrorNotImplementedException; {:try_start_0 .. :try_end_0} :catch_2 .catchall {:try_start_0 .. :try_end_0} :catchall_0 goto :goto_0 :catchall_0 move-exception p1 goto :goto_2 :cond_0 :goto_0 :try_start_1 iget-boolean p1, p0, Lk0/i0/a/b;->unsubscribed:Z if-nez p1, :cond_2 iget-object p1, p0, Lk0/i0/a/b;->subscriber:Lrx/Subscriber; invoke-interface {p1}, Ll0/g;->onCompleted()V :try_end_1 .catch Lrx/exceptions/OnCompletedFailedException; {:try_start_1 .. :try_end_1} :catch_0 .catch Lrx/exceptions/OnErrorFailedException; {:try_start_1 .. :try_end_1} :catch_0 .catch Lrx/exceptions/OnErrorNotImplementedException; {:try_start_1 .. :try_end_1} :catch_0 .catchall {:try_start_1 .. :try_end_1} :catchall_1 goto :goto_1 :catchall_1 move-exception p1 invoke-static {p1}, Lc0/j/a;->X(Ljava/lang/Throwable;)V sget-object p1, Ll0/o/o;->f:Ll0/o/o; invoke-virtual {p1}, Ll0/o/o;->b()Ll0/o/b; move-result-object p1 if-eqz p1, :cond_1 goto :goto_1 :cond_1 throw v0 :catch_0 sget-object p1, Ll0/o/o;->f:Ll0/o/o; invoke-virtual {p1}, Ll0/o/o;->b()Ll0/o/b; move-result-object p1 if-eqz p1, :cond_3 :cond_2 :goto_1 return-void :cond_3 throw v0 :goto_2 invoke-static {p1}, Lc0/j/a;->X(Ljava/lang/Throwable;)V :try_start_2 iget-object v1, p0, Lk0/i0/a/b;->subscriber:Lrx/Subscriber; invoke-interface {v1, p1}, Ll0/g;->onError(Ljava/lang/Throwable;)V :try_end_2 .catch Lrx/exceptions/OnCompletedFailedException; {:try_start_2 .. :try_end_2} :catch_1 .catch Lrx/exceptions/OnErrorFailedException; {:try_start_2 .. :try_end_2} :catch_1 .catch Lrx/exceptions/OnErrorNotImplementedException; {:try_start_2 .. :try_end_2} :catch_1 .catchall {:try_start_2 .. :try_end_2} :catchall_2 goto :goto_3 :catchall_2 move-exception v1 invoke-static {v1}, Lc0/j/a;->X(Ljava/lang/Throwable;)V new-instance v2, Lrx/exceptions/CompositeException; const/4 v3, 0x2 new-array v3, v3, [Ljava/lang/Throwable; const/4 v4, 0x0 aput-object p1, v3, v4 const/4 p1, 0x1 aput-object v1, v3, p1 invoke-direct {v2, v3}, Lrx/exceptions/CompositeException;->([Ljava/lang/Throwable;)V sget-object p1, Ll0/o/o;->f:Ll0/o/o; invoke-virtual {p1}, Ll0/o/o;->b()Ll0/o/b; move-result-object p1 if-eqz p1, :cond_4 goto :goto_3 :cond_4 throw v0 :catch_1 sget-object p1, Ll0/o/o;->f:Ll0/o/o; invoke-virtual {p1}, Ll0/o/o;->b()Ll0/o/b; move-result-object p1 if-eqz p1, :cond_5 :goto_3 return-void :cond_5 throw v0 :catch_2 sget-object p1, Ll0/o/o;->f:Ll0/o/o; invoke-virtual {p1}, Ll0/o/o;->b()Ll0/o/b; move-result-object p1 if-eqz p1, :cond_6 return-void :cond_6 throw v0 .end method .method public b(Ljava/lang/Throwable;)V .locals 5 const/4 v0, 0x3 invoke-virtual {p0, v0}, Ljava/util/concurrent/atomic/AtomicInteger;->set(I)V iget-boolean v0, p0, Lk0/i0/a/b;->unsubscribed:Z if-nez v0, :cond_2 const/4 v0, 0x0 :try_start_0 iget-object v1, p0, Lk0/i0/a/b;->subscriber:Lrx/Subscriber; invoke-interface {v1, p1}, Ll0/g;->onError(Ljava/lang/Throwable;)V :try_end_0 .catch Lrx/exceptions/OnCompletedFailedException; {:try_start_0 .. :try_end_0} :catch_0 .catch Lrx/exceptions/OnErrorFailedException; {:try_start_0 .. :try_end_0} :catch_0 .catch Lrx/exceptions/OnErrorNotImplementedException; {:try_start_0 .. :try_end_0} :catch_0 .catchall {:try_start_0 .. :try_end_0} :catchall_0 goto :goto_0 :catchall_0 move-exception v1 invoke-static {v1}, Lc0/j/a;->X(Ljava/lang/Throwable;)V new-instance v2, Lrx/exceptions/CompositeException; const/4 v3, 0x2 new-array v3, v3, [Ljava/lang/Throwable; const/4 v4, 0x0 aput-object p1, v3, v4 const/4 p1, 0x1 aput-object v1, v3, p1 invoke-direct {v2, v3}, Lrx/exceptions/CompositeException;->([Ljava/lang/Throwable;)V sget-object p1, Ll0/o/o;->f:Ll0/o/o; invoke-virtual {p1}, Ll0/o/o;->b()Ll0/o/b; move-result-object p1 if-eqz p1, :cond_0 goto :goto_0 :cond_0 throw v0 :catch_0 sget-object p1, Ll0/o/o;->f:Ll0/o/o; invoke-virtual {p1}, Ll0/o/o;->b()Ll0/o/b; move-result-object p1 if-eqz p1, :cond_1 goto :goto_0 :cond_1 throw v0 :cond_2 :goto_0 return-void .end method .method public c(Lk0/b0;)V .locals 4 .annotation system Ldalvik/annotation/Signature; value = { "(", "Lk0/b0<", "TT;>;)V" } .end annotation :cond_0 invoke-virtual {p0}, Ljava/util/concurrent/atomic/AtomicInteger;->get()I move-result v0 const/4 v1, 0x2 if-eqz v0, :cond_3 const/4 v2, 0x3 const/4 v3, 0x1 if-eq v0, v3, :cond_2 if-eq v0, v1, :cond_1 if-eq v0, v2, :cond_1 new-instance p1, Ljava/lang/IllegalStateException; const-string v1, "Unknown state: " invoke-static {v1, v0}, Lf/e/c/a/a;->i(Ljava/lang/String;I)Ljava/lang/String; move-result-object v0 invoke-direct {p1, v0}, Ljava/lang/IllegalStateException;->(Ljava/lang/String;)V throw p1 :cond_1 new-instance p1, Ljava/lang/AssertionError; invoke-direct {p1}, Ljava/lang/AssertionError;->()V throw p1 :cond_2 invoke-virtual {p0, v3, v2}, Ljava/util/concurrent/atomic/AtomicInteger;->compareAndSet(II)Z move-result v0 if-eqz v0, :cond_0 invoke-virtual {p0, p1}, Lk0/i0/a/b;->a(Lk0/b0;)V return-void :cond_3 iput-object p1, p0, Lk0/i0/a/b;->response:Lk0/b0; const/4 v0, 0x0 invoke-virtual {p0, v0, v1}, Ljava/util/concurrent/atomic/AtomicInteger;->compareAndSet(II)Z move-result v0 if-eqz v0, :cond_0 return-void .end method .method public isUnsubscribed()Z .locals 1 iget-boolean v0, p0, Lk0/i0/a/b;->unsubscribed:Z return v0 .end method .method public n(J)V .locals 3 const-wide/16 v0, 0x0 cmp-long v2, p1, v0 if-nez v2, :cond_0 return-void :cond_0 invoke-virtual {p0}, Ljava/util/concurrent/atomic/AtomicInteger;->get()I move-result p1 const/4 p2, 0x1 if-eqz p1, :cond_4 if-eq p1, p2, :cond_3 const/4 p2, 0x3 const/4 v0, 0x2 if-eq p1, v0, :cond_2 if-ne p1, p2, :cond_1 goto :goto_0 :cond_1 new-instance p2, Ljava/lang/IllegalStateException; const-string v0, "Unknown state: " invoke-static {v0, p1}, Lf/e/c/a/a;->i(Ljava/lang/String;I)Ljava/lang/String; move-result-object p1 invoke-direct {p2, p1}, Ljava/lang/IllegalStateException;->(Ljava/lang/String;)V throw p2 :cond_2 invoke-virtual {p0, v0, p2}, Ljava/util/concurrent/atomic/AtomicInteger;->compareAndSet(II)Z move-result p1 if-eqz p1, :cond_0 iget-object p1, p0, Lk0/i0/a/b;->response:Lk0/b0; invoke-virtual {p0, p1}, Lk0/i0/a/b;->a(Lk0/b0;)V :cond_3 :goto_0 return-void :cond_4 const/4 p1, 0x0 invoke-virtual {p0, p1, p2}, Ljava/util/concurrent/atomic/AtomicInteger;->compareAndSet(II)Z move-result p1 if-eqz p1, :cond_0 return-void .end method .method public unsubscribe()V .locals 1 const/4 v0, 0x1 iput-boolean v0, p0, Lk0/i0/a/b;->unsubscribed:Z iget-object v0, p0, Lk0/i0/a/b;->call:Lk0/d; invoke-interface {v0}, Lk0/d;->cancel()V return-void .end method