apkfuckery/com.discord/smali/okhttp3/x$a.smali

127 lines
2.7 KiB
Smali
Raw Normal View History

2019-02-27 21:13:14 +00:00
.class public final Lokhttp3/x$a;
2019-02-04 20:08:30 +00:00
.super Ljava/io/Reader;
2019-02-04 20:29:01 +00:00
.source "ResponseBody.java"
2019-02-04 20:08:30 +00:00
# annotations
.annotation system Ldalvik/annotation/EnclosingClass;
value = Lokhttp3/x;
.end annotation
.annotation system Ldalvik/annotation/InnerClass;
2019-02-27 21:13:14 +00:00
accessFlags = 0x19
2019-02-04 20:08:30 +00:00
name = "a"
.end annotation
# instance fields
2019-03-02 23:27:57 +00:00
.field private final bmo:Ljava/nio/charset/Charset;
2019-02-04 20:08:30 +00:00
2019-03-02 23:27:57 +00:00
.field private final bob:Lokio/d;
2019-02-04 20:08:30 +00:00
2019-03-02 23:27:57 +00:00
.field private boc:Ljava/io/Reader;
2019-02-17 02:24:41 +00:00
.annotation runtime Ljavax/annotation/Nullable;
.end annotation
.end field
2019-02-04 20:08:30 +00:00
.field private closed:Z
# direct methods
2019-02-27 21:13:14 +00:00
.method public constructor <init>(Lokio/d;Ljava/nio/charset/Charset;)V
2019-02-04 20:08:30 +00:00
.locals 0
invoke-direct {p0}, Ljava/io/Reader;-><init>()V
2019-03-02 23:27:57 +00:00
iput-object p1, p0, Lokhttp3/x$a;->bob:Lokio/d;
2019-02-04 20:08:30 +00:00
2019-03-02 23:27:57 +00:00
iput-object p2, p0, Lokhttp3/x$a;->bmo:Ljava/nio/charset/Charset;
2019-02-04 20:08:30 +00:00
return-void
.end method
# virtual methods
.method public final close()V
.locals 1
.annotation system Ldalvik/annotation/Throws;
value = {
Ljava/io/IOException;
}
.end annotation
const/4 v0, 0x1
iput-boolean v0, p0, Lokhttp3/x$a;->closed:Z
2019-03-02 23:27:57 +00:00
iget-object v0, p0, Lokhttp3/x$a;->boc:Ljava/io/Reader;
2019-02-04 20:08:30 +00:00
if-eqz v0, :cond_0
invoke-virtual {v0}, Ljava/io/Reader;->close()V
return-void
:cond_0
2019-03-02 23:27:57 +00:00
iget-object v0, p0, Lokhttp3/x$a;->bob:Lokio/d;
2019-02-04 20:08:30 +00:00
invoke-interface {v0}, Lokio/d;->close()V
return-void
.end method
.method public final read([CII)I
.locals 3
.annotation system Ldalvik/annotation/Throws;
value = {
Ljava/io/IOException;
}
.end annotation
iget-boolean v0, p0, Lokhttp3/x$a;->closed:Z
if-nez v0, :cond_1
2019-03-02 23:27:57 +00:00
iget-object v0, p0, Lokhttp3/x$a;->boc:Ljava/io/Reader;
2019-02-04 20:08:30 +00:00
if-nez v0, :cond_0
2019-03-02 23:27:57 +00:00
iget-object v0, p0, Lokhttp3/x$a;->bob:Lokio/d;
2019-02-04 20:08:30 +00:00
2019-03-02 23:27:57 +00:00
iget-object v1, p0, Lokhttp3/x$a;->bmo:Ljava/nio/charset/Charset;
2019-02-04 20:08:30 +00:00
invoke-static {v0, v1}, Lokhttp3/internal/c;->a(Lokio/d;Ljava/nio/charset/Charset;)Ljava/nio/charset/Charset;
move-result-object v0
new-instance v1, Ljava/io/InputStreamReader;
2019-03-02 23:27:57 +00:00
iget-object v2, p0, Lokhttp3/x$a;->bob:Lokio/d;
2019-02-04 20:08:30 +00:00
2019-02-27 21:13:14 +00:00
invoke-interface {v2}, Lokio/d;->BX()Ljava/io/InputStream;
2019-02-04 20:08:30 +00:00
move-result-object v2
invoke-direct {v1, v2, v0}, Ljava/io/InputStreamReader;-><init>(Ljava/io/InputStream;Ljava/nio/charset/Charset;)V
2019-03-02 23:27:57 +00:00
iput-object v1, p0, Lokhttp3/x$a;->boc:Ljava/io/Reader;
2019-02-04 20:08:30 +00:00
move-object v0, v1
:cond_0
invoke-virtual {v0, p1, p2, p3}, Ljava/io/Reader;->read([CII)I
move-result p1
return p1
:cond_1
new-instance p1, Ljava/io/IOException;
const-string p2, "Stream closed"
invoke-direct {p1, p2}, Ljava/io/IOException;-><init>(Ljava/lang/String;)V
throw p1
.end method