2022-06-10 21:38:30 +09:00

177 lines
4.2 KiB
Smali

.class public final Lretrofit2/adapter/rxjava2/Result;
.super Ljava/lang/Object;
.source "Result.java"
# annotations
.annotation system Ldalvik/annotation/Signature;
value = {
"<T:",
"Ljava/lang/Object;",
">",
"Ljava/lang/Object;"
}
.end annotation
# instance fields
.field private final error:Ljava/lang/Throwable;
.annotation runtime Ljavax/annotation/Nullable;
.end annotation
.end field
.field private final response:Lretrofit2/Response;
.annotation system Ldalvik/annotation/Signature;
value = {
"Lretrofit2/Response<",
"TT;>;"
}
.end annotation
.annotation runtime Ljavax/annotation/Nullable;
.end annotation
.end field
# direct methods
.method private constructor <init>(Lretrofit2/Response;Ljava/lang/Throwable;)V
.locals 0
.param p1 # Lretrofit2/Response;
.annotation runtime Ljavax/annotation/Nullable;
.end annotation
.end param
.param p2 # Ljava/lang/Throwable;
.annotation runtime Ljavax/annotation/Nullable;
.end annotation
.end param
.annotation system Ldalvik/annotation/Signature;
value = {
"(",
"Lretrofit2/Response<",
"TT;>;",
"Ljava/lang/Throwable;",
")V"
}
.end annotation
.line 1
invoke-direct {p0}, Ljava/lang/Object;-><init>()V
.line 2
iput-object p1, p0, Lretrofit2/adapter/rxjava2/Result;->response:Lretrofit2/Response;
.line 3
iput-object p2, p0, Lretrofit2/adapter/rxjava2/Result;->error:Ljava/lang/Throwable;
return-void
.end method
.method public static error(Ljava/lang/Throwable;)Lretrofit2/adapter/rxjava2/Result;
.locals 2
.annotation system Ldalvik/annotation/Signature;
value = {
"<T:",
"Ljava/lang/Object;",
">(",
"Ljava/lang/Throwable;",
")",
"Lretrofit2/adapter/rxjava2/Result<",
"TT;>;"
}
.end annotation
const-string v0, "error == null"
.line 1
invoke-static {p0, v0}, Ljava/util/Objects;->requireNonNull(Ljava/lang/Object;Ljava/lang/String;)Ljava/lang/Object;
.line 2
new-instance v0, Lretrofit2/adapter/rxjava2/Result;
const/4 v1, 0x0
invoke-direct {v0, v1, p0}, Lretrofit2/adapter/rxjava2/Result;-><init>(Lretrofit2/Response;Ljava/lang/Throwable;)V
return-object v0
.end method
.method public static response(Lretrofit2/Response;)Lretrofit2/adapter/rxjava2/Result;
.locals 2
.annotation system Ldalvik/annotation/Signature;
value = {
"<T:",
"Ljava/lang/Object;",
">(",
"Lretrofit2/Response<",
"TT;>;)",
"Lretrofit2/adapter/rxjava2/Result<",
"TT;>;"
}
.end annotation
const-string v0, "response == null"
.line 1
invoke-static {p0, v0}, Ljava/util/Objects;->requireNonNull(Ljava/lang/Object;Ljava/lang/String;)Ljava/lang/Object;
.line 2
new-instance v0, Lretrofit2/adapter/rxjava2/Result;
const/4 v1, 0x0
invoke-direct {v0, p0, v1}, Lretrofit2/adapter/rxjava2/Result;-><init>(Lretrofit2/Response;Ljava/lang/Throwable;)V
return-object v0
.end method
# virtual methods
.method public error()Ljava/lang/Throwable;
.locals 1
.annotation runtime Ljavax/annotation/Nullable;
.end annotation
.line 3
iget-object v0, p0, Lretrofit2/adapter/rxjava2/Result;->error:Ljava/lang/Throwable;
return-object v0
.end method
.method public isError()Z
.locals 1
.line 1
iget-object v0, p0, Lretrofit2/adapter/rxjava2/Result;->error:Ljava/lang/Throwable;
if-eqz v0, :cond_0
const/4 v0, 0x1
goto :goto_0
:cond_0
const/4 v0, 0x0
:goto_0
return v0
.end method
.method public response()Lretrofit2/Response;
.locals 1
.annotation system Ldalvik/annotation/Signature;
value = {
"()",
"Lretrofit2/Response<",
"TT;>;"
}
.end annotation
.annotation runtime Ljavax/annotation/Nullable;
.end annotation
.line 3
iget-object v0, p0, Lretrofit2/adapter/rxjava2/Result;->response:Lretrofit2/Response;
return-object v0
.end method