FramedConnection$Reader.smali
.class Lcom/squareup/okhttp/internal/framed/FramedConnection$Reader;
.super Lcom/squareup/okhttp/internal/NamedRunnable;
.source "FramedConnection.java"
# interfaces
.implements Lcom/squareup/okhttp/internal/framed/FrameReader$Handler;
# annotations
.annotation system Ldalvik/annotation/EnclosingClass;
value = Lcom/squareup/okhttp/internal/framed/FramedConnection;
.end annotation
.annotation system Ldalvik/annotation/InnerClass;
accessFlags = 0x0
name = "Reader"
.end annotation
# instance fields
.field frameReader:Lcom/squareup/okhttp/internal/framed/FrameReader;
.field final synthetic this$0:Lcom/squareup/okhttp/internal/framed/FramedConnection;
# direct methods
.method private constructor <init>(Lcom/squareup/okhttp/internal/framed/FramedConnection;)V
.registers 4
.line 2
iput-object p1, p0, Lcom/squareup/okhttp/internal/framed/FramedConnection$Reader;->this$0:Lcom/squareup/okhttp/internal/framed/FramedConnection;
const/4 v0, 0x1
.line 3
new-array v0, v0, [Ljava/lang/Object;
# getter for: Lcom/squareup/okhttp/internal/framed/FramedConnection;->hostName:Ljava/lang/String;
invoke-static {p1}, Lcom/squareup/okhttp/internal/framed/FramedConnection;->access$900(Lcom/squareup/okhttp/internal/framed/FramedConnection;)Ljava/lang/String;
move-result-object p1
const/4 v1, 0x0
aput-object p1, v0, v1
const-string p1, "OkHttp %s"
invoke-direct {p0, p1, v0}, Lcom/squareup/okhttp/internal/NamedRunnable;-><init>(Ljava/lang/String;[Ljava/lang/Object;)V
return-void
.end method
.method synthetic constructor <init>(Lcom/squareup/okhttp/internal/framed/FramedConnection;Lcom/squareup/okhttp/internal/framed/FramedConnection$1;)V
.registers 3
.line 1
invoke-direct {p0, p1}, Lcom/squareup/okhttp/internal/framed/FramedConnection$Reader;-><init>(Lcom/squareup/okhttp/internal/framed/FramedConnection;)V
return-void
.end method
.method private ackSettingsLater(Lcom/squareup/okhttp/internal/framed/Settings;)V
.registers 7
.line 1
# getter for: Lcom/squareup/okhttp/internal/framed/FramedConnection;->executor:Ljava/util/concurrent/ExecutorService;
invoke-static {}, Lcom/squareup/okhttp/internal/framed/FramedConnection;->access$1900()Ljava/util/concurrent/ExecutorService;
move-result-object v0
new-instance v1, Lcom/squareup/okhttp/internal/framed/FramedConnection$Reader$2;
const/4 v2, 0x1
new-array v2, v2, [Ljava/lang/Object;
iget-object v3, p0, Lcom/squareup/okhttp/internal/framed/FramedConnection$Reader;->this$0:Lcom/squareup/okhttp/internal/framed/FramedConnection;
# getter for: Lcom/squareup/okhttp/internal/framed/FramedConnection;->hostName:Ljava/lang/String;
invoke-static {v3}, Lcom/squareup/okhttp/internal/framed/FramedConnection;->access$900(Lcom/squareup/okhttp/internal/framed/FramedConnection;)Ljava/lang/String;
move-result-object v3
const/4 v4, 0x0
aput-object v3, v2, v4
const-string v3, "OkHttp %s ACK Settings"
invoke-direct {v1, p0, v3, v2, p1}, Lcom/squareup/okhttp/internal/framed/FramedConnection$Reader$2;-><init>(Lcom/squareup/okhttp/internal/framed/FramedConnection$Reader;Ljava/lang/String;[Ljava/lang/Object;Lcom/squareup/okhttp/internal/framed/Settings;)V
invoke-interface {v0, v1}, Ljava/util/concurrent/ExecutorService;->execute(Ljava/lang/Runnable;)V
return-void
.end method
# virtual methods
.method public ackSettings()V
.registers 1
return-void
.end method
.method public alternateService(ILjava/lang/String;Lokio/ByteString;Ljava/lang/String;IJ)V
.registers 8
return-void
.end method
.method public data(ZILokio/BufferedSource;I)V
.registers 6
.annotation system Ldalvik/annotation/Throws;
value = {
Ljava/io/IOException;
}
.end annotation
.line 1
iget-object v0, p0, Lcom/squareup/okhttp/internal/framed/FramedConnection$Reader;->this$0:Lcom/squareup/okhttp/internal/framed/FramedConnection;
# invokes: Lcom/squareup/okhttp/internal/framed/FramedConnection;->pushedStream(I)Z
invoke-static {v0, p2}, Lcom/squareup/okhttp/internal/framed/FramedConnection;->access$1100(Lcom/squareup/okhttp/internal/framed/FramedConnection;I)Z
move-result v0
if-eqz v0, :cond_e
.line 2
iget-object v0, p0, Lcom/squareup/okhttp/internal/framed/FramedConnection$Reader;->this$0:Lcom/squareup/okhttp/internal/framed/FramedConnection;
# invokes: Lcom/squareup/okhttp/internal/framed/FramedConnection;->pushDataLater(ILokio/BufferedSource;IZ)V
invoke-static {v0, p2, p3, p4, p1}, Lcom/squareup/okhttp/internal/framed/FramedConnection;->access$1200(Lcom/squareup/okhttp/internal/framed/FramedConnection;ILokio/BufferedSource;IZ)V
return-void
.line 3
:cond_e
iget-object v0, p0, Lcom/squareup/okhttp/internal/framed/FramedConnection$Reader;->this$0:Lcom/squareup/okhttp/internal/framed/FramedConnection;
invoke-virtual {v0, p2}, Lcom/squareup/okhttp/internal/framed/FramedConnection;->getStream(I)Lcom/squareup/okhttp/internal/framed/FramedStream;
move-result-object v0
if-nez v0, :cond_22
.line 4
iget-object p1, p0, Lcom/squareup/okhttp/internal/framed/FramedConnection$Reader;->this$0:Lcom/squareup/okhttp/internal/framed/FramedConnection;
sget-object v0, Lcom/squareup/okhttp/internal/framed/ErrorCode;->INVALID_STREAM:Lcom/squareup/okhttp/internal/framed/ErrorCode;
invoke-virtual {p1, p2, v0}, Lcom/squareup/okhttp/internal/framed/FramedConnection;->writeSynResetLater(ILcom/squareup/okhttp/internal/framed/ErrorCode;)V
int-to-long p1, p4
.line 5
invoke-interface {p3, p1, p2}, Lokio/BufferedSource;->skip(J)V
return-void
.line 6
:cond_22
invoke-virtual {v0, p3, p4}, Lcom/squareup/okhttp/internal/framed/FramedStream;->receiveData(Lokio/BufferedSource;I)V
if-eqz p1, :cond_2a
.line 7
invoke-virtual {v0}, Lcom/squareup/okhttp/internal/framed/FramedStream;->receiveFin()V
:cond_2a
return-void
.end method
.method protected execute()V
.registers 6
.line 1
sget-object v0, Lcom/squareup/okhttp/internal/framed/ErrorCode;->INTERNAL_ERROR:Lcom/squareup/okhttp/internal/framed/ErrorCode;
.line 2
:try_start_2
iget-object v1, p0, Lcom/squareup/okhttp/internal/framed/FramedConnection$Reader;->this$0:Lcom/squareup/okhttp/internal/framed/FramedConnection;
iget-object v1, v1, Lcom/squareup/okhttp/internal/framed/FramedConnection;->variant:Lcom/squareup/okhttp/internal/framed/Variant;
iget-object v2, p0, Lcom/squareup/okhttp/internal/framed/FramedConnection$Reader;->this$0:Lcom/squareup/okhttp/internal/framed/FramedConnection;
iget-object v2, v2, Lcom/squareup/okhttp/internal/framed/FramedConnection;->socket:Ljava/net/Socket;
invoke-static {v2}, Lokio/Okio;->source(Ljava/net/Socket;)Lokio/Source;
move-result-object v2
invoke-static {v2}, Lokio/Okio;->buffer(Lokio/Source;)Lokio/BufferedSource;
move-result-object v2
iget-object v3, p0, Lcom/squareup/okhttp/internal/framed/FramedConnection$Reader;->this$0:Lcom/squareup/okhttp/internal/framed/FramedConnection;
iget-boolean v3, v3, Lcom/squareup/okhttp/internal/framed/FramedConnection;->client:Z
invoke-interface {v1, v2, v3}, Lcom/squareup/okhttp/internal/framed/Variant;->newReader(Lokio/BufferedSource;Z)Lcom/squareup/okhttp/internal/framed/FrameReader;
move-result-object v1
iput-object v1, p0, Lcom/squareup/okhttp/internal/framed/FramedConnection$Reader;->frameReader:Lcom/squareup/okhttp/internal/framed/FrameReader;
.line 3
iget-object v1, p0, Lcom/squareup/okhttp/internal/framed/FramedConnection$Reader;->this$0:Lcom/squareup/okhttp/internal/framed/FramedConnection;
iget-boolean v1, v1, Lcom/squareup/okhttp/internal/framed/FramedConnection;->client:Z
if-nez v1, :cond_27
.line 4
iget-object v1, p0, Lcom/squareup/okhttp/internal/framed/FramedConnection$Reader;->frameReader:Lcom/squareup/okhttp/internal/framed/FrameReader;
invoke-interface {v1}, Lcom/squareup/okhttp/internal/framed/FrameReader;->readConnectionPreface()V
.line 5
:cond_27
:goto_27
iget-object v1, p0, Lcom/squareup/okhttp/internal/framed/FramedConnection$Reader;->frameReader:Lcom/squareup/okhttp/internal/framed/FrameReader;
invoke-interface {v1, p0}, Lcom/squareup/okhttp/internal/framed/FrameReader;->nextFrame(Lcom/squareup/okhttp/internal/framed/FrameReader$Handler;)Z
move-result v1
if-eqz v1, :cond_30
goto :goto_27
.line 6
:cond_30
sget-object v1, Lcom/squareup/okhttp/internal/framed/ErrorCode;->NO_ERROR:Lcom/squareup/okhttp/internal/framed/ErrorCode;
:try_end_32
.catch Ljava/io/IOException; {:try_start_2 .. :try_end_32} :catch_3a
.catchall {:try_start_2 .. :try_end_32} :catchall_37
.line 7
:try_start_32
sget-object v0, Lcom/squareup/okhttp/internal/framed/ErrorCode;->CANCEL:Lcom/squareup/okhttp/internal/framed/ErrorCode;
:try_end_34
.catch Ljava/io/IOException; {:try_start_32 .. :try_end_34} :catch_3b
.catchall {:try_start_32 .. :try_end_34} :catchall_4a
.line 8
:try_start_34
iget-object v2, p0, Lcom/squareup/okhttp/internal/framed/FramedConnection$Reader;->this$0:Lcom/squareup/okhttp/internal/framed/FramedConnection;
:try_end_36
.catch Ljava/io/IOException; {:try_start_34 .. :try_end_36} :catch_44
goto :goto_41
:catchall_37
move-exception v1
move-object v2, v0
goto :goto_4e
:catch_3a
move-object v1, v0
.line 9
:catch_3b
:try_start_3b
sget-object v1, Lcom/squareup/okhttp/internal/framed/ErrorCode;->PROTOCOL_ERROR:Lcom/squareup/okhttp/internal/framed/ErrorCode;
.line 10
sget-object v0, Lcom/squareup/okhttp/internal/framed/ErrorCode;->PROTOCOL_ERROR:Lcom/squareup/okhttp/internal/framed/ErrorCode;
:try_end_3f
.catchall {:try_start_3b .. :try_end_3f} :catchall_4a
.line 11
:try_start_3f
iget-object v2, p0, Lcom/squareup/okhttp/internal/framed/FramedConnection$Reader;->this$0:Lcom/squareup/okhttp/internal/framed/FramedConnection;
:goto_41
# invokes: Lcom/squareup/okhttp/internal/framed/FramedConnection;->close(Lcom/squareup/okhttp/internal/framed/ErrorCode;Lcom/squareup/okhttp/internal/framed/ErrorCode;)V
invoke-static {v2, v1, v0}, Lcom/squareup/okhttp/internal/framed/FramedConnection;->access$1000(Lcom/squareup/okhttp/internal/framed/FramedConnection;Lcom/squareup/okhttp/internal/framed/ErrorCode;Lcom/squareup/okhttp/internal/framed/ErrorCode;)V
:try_end_44
.catch Ljava/io/IOException; {:try_start_3f .. :try_end_44} :catch_44
.line 12
:catch_44
iget-object v0, p0, Lcom/squareup/okhttp/internal/framed/FramedConnection$Reader;->frameReader:Lcom/squareup/okhttp/internal/framed/FrameReader;
invoke-static {v0}, Lcom/squareup/okhttp/internal/Util;->closeQuietly(Ljava/io/Closeable;)V
return-void
:catchall_4a
move-exception v2
move-object v4, v2
move-object v2, v1
move-object v1, v4
.line 13
:goto_4e
:try_start_4e
iget-object v3, p0, Lcom/squareup/okhttp/internal/framed/FramedConnection$Reader;->this$0:Lcom/squareup/okhttp/internal/framed/FramedConnection;
# invokes: Lcom/squareup/okhttp/internal/framed/FramedConnection;->close(Lcom/squareup/okhttp/internal/framed/ErrorCode;Lcom/squareup/okhttp/internal/framed/ErrorCode;)V
invoke-static {v3, v2, v0}, Lcom/squareup/okhttp/internal/framed/FramedConnection;->access$1000(Lcom/squareup/okhttp/internal/framed/FramedConnection;Lcom/squareup/okhttp/internal/framed/ErrorCode;Lcom/squareup/okhttp/internal/framed/ErrorCode;)V
:try_end_53
.catch Ljava/io/IOException; {:try_start_4e .. :try_end_53} :catch_53
.line 14
:catch_53
iget-object v0, p0, Lcom/squareup/okhttp/internal/framed/FramedConnection$Reader;->frameReader:Lcom/squareup/okhttp/internal/framed/FrameReader;
invoke-static {v0}, Lcom/squareup/okhttp/internal/Util;->closeQuietly(Ljava/io/Closeable;)V
goto :goto_5a
:goto_59
throw v1
:goto_5a
goto :goto_59
.end method
.method public goAway(ILcom/squareup/okhttp/internal/framed/ErrorCode;Lokio/ByteString;)V
.registers 7
.line 1
invoke-virtual {p3}, Lokio/ByteString;->size()I
.line 2
iget-object p2, p0, Lcom/squareup/okhttp/internal/framed/FramedConnection$Reader;->this$0:Lcom/squareup/okhttp/internal/framed/FramedConnection;
monitor-enter p2
.line 3
:try_start_6
iget-object p3, p0, Lcom/squareup/okhttp/internal/framed/FramedConnection$Reader;->this$0:Lcom/squareup/okhttp/internal/framed/FramedConnection;
# getter for: Lcom/squareup/okhttp/internal/framed/FramedConnection;->streams:Ljava/util/Map;
invoke-static {p3}, Lcom/squareup/okhttp/internal/framed/FramedConnection;->access$1700(Lcom/squareup/okhttp/internal/framed/FramedConnection;)Ljava/util/Map;
move-result-object p3
invoke-interface {p3}, Ljava/util/Map;->values()Ljava/util/Collection;
move-result-object p3
iget-object v0, p0, Lcom/squareup/okhttp/internal/framed/FramedConnection$Reader;->this$0:Lcom/squareup/okhttp/internal/framed/FramedConnection;
# getter for: Lcom/squareup/okhttp/internal/framed/FramedConnection;->streams:Ljava/util/Map;
invoke-static {v0}, Lcom/squareup/okhttp/internal/framed/FramedConnection;->access$1700(Lcom/squareup/okhttp/internal/framed/FramedConnection;)Ljava/util/Map;
move-result-object v0
invoke-interface {v0}, Ljava/util/Map;->size()I
move-result v0
new-array v0, v0, [Lcom/squareup/okhttp/internal/framed/FramedStream;
invoke-interface {p3, v0}, Ljava/util/Collection;->toArray([Ljava/lang/Object;)[Ljava/lang/Object;
move-result-object p3
check-cast p3, [Lcom/squareup/okhttp/internal/framed/FramedStream;
.line 4
iget-object v0, p0, Lcom/squareup/okhttp/internal/framed/FramedConnection$Reader;->this$0:Lcom/squareup/okhttp/internal/framed/FramedConnection;
const/4 v1, 0x1
# setter for: Lcom/squareup/okhttp/internal/framed/FramedConnection;->shutdown:Z
invoke-static {v0, v1}, Lcom/squareup/okhttp/internal/framed/FramedConnection;->access$1402(Lcom/squareup/okhttp/internal/framed/FramedConnection;Z)Z
.line 5
monitor-exit p2
:try_end_29
.catchall {:try_start_6 .. :try_end_29} :catchall_4d
.line 6
array-length p2, p3
const/4 v0, 0x0
:goto_2b
if-ge v0, p2, :cond_4c
aget-object v1, p3, v0
.line 7
invoke-virtual {v1}, Lcom/squareup/okhttp/internal/framed/FramedStream;->getId()I
move-result v2
if-le v2, p1, :cond_49
invoke-virtual {v1}, Lcom/squareup/okhttp/internal/framed/FramedStream;->isLocallyInitiated()Z
move-result v2
if-eqz v2, :cond_49
.line 8
sget-object v2, Lcom/squareup/okhttp/internal/framed/ErrorCode;->REFUSED_STREAM:Lcom/squareup/okhttp/internal/framed/ErrorCode;
invoke-virtual {v1, v2}, Lcom/squareup/okhttp/internal/framed/FramedStream;->receiveRstStream(Lcom/squareup/okhttp/internal/framed/ErrorCode;)V
.line 9
iget-object v2, p0, Lcom/squareup/okhttp/internal/framed/FramedConnection$Reader;->this$0:Lcom/squareup/okhttp/internal/framed/FramedConnection;
invoke-virtual {v1}, Lcom/squareup/okhttp/internal/framed/FramedStream;->getId()I
move-result v1
invoke-virtual {v2, v1}, Lcom/squareup/okhttp/internal/framed/FramedConnection;->removeStream(I)Lcom/squareup/okhttp/internal/framed/FramedStream;
:cond_49
add-int/lit8 v0, v0, 0x1
goto :goto_2b
:cond_4c
return-void
:catchall_4d
move-exception p1
.line 10
:try_start_4e
monitor-exit p2
:try_end_4f
.catchall {:try_start_4e .. :try_end_4f} :catchall_4d
goto :goto_51
:goto_50
throw p1
:goto_51
goto :goto_50
.end method
.method public headers(ZZIILjava/util/List;Lcom/squareup/okhttp/internal/framed/HeadersMode;)V
.registers 15
.annotation system Ldalvik/annotation/Signature;
value = {
"(ZZII",
"Ljava/util/List<",
"Lcom/squareup/okhttp/internal/framed/Header;",
">;",
"Lcom/squareup/okhttp/internal/framed/HeadersMode;",
")V"
}
.end annotation
.line 1
iget-object p4, p0, Lcom/squareup/okhttp/internal/framed/FramedConnection$Reader;->this$0:Lcom/squareup/okhttp/internal/framed/FramedConnection;
# invokes: Lcom/squareup/okhttp/internal/framed/FramedConnection;->pushedStream(I)Z
invoke-static {p4, p3}, Lcom/squareup/okhttp/internal/framed/FramedConnection;->access$1100(Lcom/squareup/okhttp/internal/framed/FramedConnection;I)Z
move-result p4
if-eqz p4, :cond_e
.line 2
iget-object p1, p0, Lcom/squareup/okhttp/internal/framed/FramedConnection$Reader;->this$0:Lcom/squareup/okhttp/internal/framed/FramedConnection;
# invokes: Lcom/squareup/okhttp/internal/framed/FramedConnection;->pushHeadersLater(ILjava/util/List;Z)V
invoke-static {p1, p3, p5, p2}, Lcom/squareup/okhttp/internal/framed/FramedConnection;->access$1300(Lcom/squareup/okhttp/internal/framed/FramedConnection;ILjava/util/List;Z)V
return-void
.line 3
:cond_e
iget-object p4, p0, Lcom/squareup/okhttp/internal/framed/FramedConnection$Reader;->this$0:Lcom/squareup/okhttp/internal/framed/FramedConnection;
monitor-enter p4
.line 4
:try_start_11
iget-object v0, p0, Lcom/squareup/okhttp/internal/framed/FramedConnection$Reader;->this$0:Lcom/squareup/okhttp/internal/framed/FramedConnection;
# getter for: Lcom/squareup/okhttp/internal/framed/FramedConnection;->shutdown:Z
invoke-static {v0}, Lcom/squareup/okhttp/internal/framed/FramedConnection;->access$1400(Lcom/squareup/okhttp/internal/framed/FramedConnection;)Z
move-result v0
if-eqz v0, :cond_1b
monitor-exit p4
return-void
.line 5
:cond_1b
iget-object v0, p0, Lcom/squareup/okhttp/internal/framed/FramedConnection$Reader;->this$0:Lcom/squareup/okhttp/internal/framed/FramedConnection;
invoke-virtual {v0, p3}, Lcom/squareup/okhttp/internal/framed/FramedConnection;->getStream(I)Lcom/squareup/okhttp/internal/framed/FramedStream;
move-result-object v0
if-nez v0, :cond_8a
.line 6
invoke-virtual {p6}, Lcom/squareup/okhttp/internal/framed/HeadersMode;->failIfStreamAbsent()Z
move-result p6
if-eqz p6, :cond_32
.line 7
iget-object p1, p0, Lcom/squareup/okhttp/internal/framed/FramedConnection$Reader;->this$0:Lcom/squareup/okhttp/internal/framed/FramedConnection;
sget-object p2, Lcom/squareup/okhttp/internal/framed/ErrorCode;->INVALID_STREAM:Lcom/squareup/okhttp/internal/framed/ErrorCode;
invoke-virtual {p1, p3, p2}, Lcom/squareup/okhttp/internal/framed/FramedConnection;->writeSynResetLater(ILcom/squareup/okhttp/internal/framed/ErrorCode;)V
.line 8
monitor-exit p4
return-void
.line 9
:cond_32
iget-object p6, p0, Lcom/squareup/okhttp/internal/framed/FramedConnection$Reader;->this$0:Lcom/squareup/okhttp/internal/framed/FramedConnection;
# getter for: Lcom/squareup/okhttp/internal/framed/FramedConnection;->lastGoodStreamId:I
invoke-static {p6}, Lcom/squareup/okhttp/internal/framed/FramedConnection;->access$1500(Lcom/squareup/okhttp/internal/framed/FramedConnection;)I
move-result p6
if-gt p3, p6, :cond_3c
monitor-exit p4
return-void
.line 10
:cond_3c
rem-int/lit8 p6, p3, 0x2
iget-object v0, p0, Lcom/squareup/okhttp/internal/framed/FramedConnection$Reader;->this$0:Lcom/squareup/okhttp/internal/framed/FramedConnection;
# getter for: Lcom/squareup/okhttp/internal/framed/FramedConnection;->nextStreamId:I
invoke-static {v0}, Lcom/squareup/okhttp/internal/framed/FramedConnection;->access$1600(Lcom/squareup/okhttp/internal/framed/FramedConnection;)I
move-result v0
const/4 v1, 0x2
rem-int/2addr v0, v1
if-ne p6, v0, :cond_4a
monitor-exit p4
return-void
.line 11
:cond_4a
new-instance p6, Lcom/squareup/okhttp/internal/framed/FramedStream;
iget-object v4, p0, Lcom/squareup/okhttp/internal/framed/FramedConnection$Reader;->this$0:Lcom/squareup/okhttp/internal/framed/FramedConnection;
move-object v2, p6
move v3, p3
move v5, p1
move v6, p2
move-object v7, p5
invoke-direct/range {v2 .. v7}, Lcom/squareup/okhttp/internal/framed/FramedStream;-><init>(ILcom/squareup/okhttp/internal/framed/FramedConnection;ZZLjava/util/List;)V
.line 12
iget-object p1, p0, Lcom/squareup/okhttp/internal/framed/FramedConnection$Reader;->this$0:Lcom/squareup/okhttp/internal/framed/FramedConnection;
# setter for: Lcom/squareup/okhttp/internal/framed/FramedConnection;->lastGoodStreamId:I
invoke-static {p1, p3}, Lcom/squareup/okhttp/internal/framed/FramedConnection;->access$1502(Lcom/squareup/okhttp/internal/framed/FramedConnection;I)I
.line 13
iget-object p1, p0, Lcom/squareup/okhttp/internal/framed/FramedConnection$Reader;->this$0:Lcom/squareup/okhttp/internal/framed/FramedConnection;
# getter for: Lcom/squareup/okhttp/internal/framed/FramedConnection;->streams:Ljava/util/Map;
invoke-static {p1}, Lcom/squareup/okhttp/internal/framed/FramedConnection;->access$1700(Lcom/squareup/okhttp/internal/framed/FramedConnection;)Ljava/util/Map;
move-result-object p1
invoke-static {p3}, Ljava/lang/Integer;->valueOf(I)Ljava/lang/Integer;
move-result-object p2
invoke-interface {p1, p2, p6}, Ljava/util/Map;->put(Ljava/lang/Object;Ljava/lang/Object;)Ljava/lang/Object;
.line 14
# getter for: Lcom/squareup/okhttp/internal/framed/FramedConnection;->executor:Ljava/util/concurrent/ExecutorService;
invoke-static {}, Lcom/squareup/okhttp/internal/framed/FramedConnection;->access$1900()Ljava/util/concurrent/ExecutorService;
move-result-object p1
new-instance p2, Lcom/squareup/okhttp/internal/framed/FramedConnection$Reader$1;
const-string p5, "OkHttp %s stream %d"
new-array v0, v1, [Ljava/lang/Object;
const/4 v1, 0x0
iget-object v2, p0, Lcom/squareup/okhttp/internal/framed/FramedConnection$Reader;->this$0:Lcom/squareup/okhttp/internal/framed/FramedConnection;
# getter for: Lcom/squareup/okhttp/internal/framed/FramedConnection;->hostName:Ljava/lang/String;
invoke-static {v2}, Lcom/squareup/okhttp/internal/framed/FramedConnection;->access$900(Lcom/squareup/okhttp/internal/framed/FramedConnection;)Ljava/lang/String;
move-result-object v2
aput-object v2, v0, v1
const/4 v1, 0x1
invoke-static {p3}, Ljava/lang/Integer;->valueOf(I)Ljava/lang/Integer;
move-result-object p3
aput-object p3, v0, v1
invoke-direct {p2, p0, p5, v0, p6}, Lcom/squareup/okhttp/internal/framed/FramedConnection$Reader$1;-><init>(Lcom/squareup/okhttp/internal/framed/FramedConnection$Reader;Ljava/lang/String;[Ljava/lang/Object;Lcom/squareup/okhttp/internal/framed/FramedStream;)V
invoke-interface {p1, p2}, Ljava/util/concurrent/ExecutorService;->execute(Ljava/lang/Runnable;)V
.line 15
monitor-exit p4
return-void
.line 16
:cond_8a
monitor-exit p4
:try_end_8b
.catchall {:try_start_11 .. :try_end_8b} :catchall_a5
.line 17
invoke-virtual {p6}, Lcom/squareup/okhttp/internal/framed/HeadersMode;->failIfStreamPresent()Z
move-result p1
if-eqz p1, :cond_9c
.line 18
sget-object p1, Lcom/squareup/okhttp/internal/framed/ErrorCode;->PROTOCOL_ERROR:Lcom/squareup/okhttp/internal/framed/ErrorCode;
invoke-virtual {v0, p1}, Lcom/squareup/okhttp/internal/framed/FramedStream;->closeLater(Lcom/squareup/okhttp/internal/framed/ErrorCode;)V
.line 19
iget-object p1, p0, Lcom/squareup/okhttp/internal/framed/FramedConnection$Reader;->this$0:Lcom/squareup/okhttp/internal/framed/FramedConnection;
invoke-virtual {p1, p3}, Lcom/squareup/okhttp/internal/framed/FramedConnection;->removeStream(I)Lcom/squareup/okhttp/internal/framed/FramedStream;
return-void
.line 20
:cond_9c
invoke-virtual {v0, p5, p6}, Lcom/squareup/okhttp/internal/framed/FramedStream;->receiveHeaders(Ljava/util/List;Lcom/squareup/okhttp/internal/framed/HeadersMode;)V
if-eqz p2, :cond_a4
.line 21
invoke-virtual {v0}, Lcom/squareup/okhttp/internal/framed/FramedStream;->receiveFin()V
:cond_a4
return-void
:catchall_a5
move-exception p1
.line 22
:try_start_a6
monitor-exit p4
:try_end_a7
.catchall {:try_start_a6 .. :try_end_a7} :catchall_a5
throw p1
.end method
.method public ping(ZII)V
.registers 6
if-eqz p1, :cond_e
.line 1
iget-object p1, p0, Lcom/squareup/okhttp/internal/framed/FramedConnection$Reader;->this$0:Lcom/squareup/okhttp/internal/framed/FramedConnection;
# invokes: Lcom/squareup/okhttp/internal/framed/FramedConnection;->removePing(I)Lcom/squareup/okhttp/internal/framed/Ping;
invoke-static {p1, p2}, Lcom/squareup/okhttp/internal/framed/FramedConnection;->access$2200(Lcom/squareup/okhttp/internal/framed/FramedConnection;I)Lcom/squareup/okhttp/internal/framed/Ping;
move-result-object p1
if-eqz p1, :cond_15
.line 2
invoke-virtual {p1}, Lcom/squareup/okhttp/internal/framed/Ping;->receive()V
goto :goto_15
.line 3
:cond_e
iget-object p1, p0, Lcom/squareup/okhttp/internal/framed/FramedConnection$Reader;->this$0:Lcom/squareup/okhttp/internal/framed/FramedConnection;
const/4 v0, 0x1
const/4 v1, 0x0
# invokes: Lcom/squareup/okhttp/internal/framed/FramedConnection;->writePingLater(ZIILcom/squareup/okhttp/internal/framed/Ping;)V
invoke-static {p1, v0, p2, p3, v1}, Lcom/squareup/okhttp/internal/framed/FramedConnection;->access$2300(Lcom/squareup/okhttp/internal/framed/FramedConnection;ZIILcom/squareup/okhttp/internal/framed/Ping;)V
:cond_15
:goto_15
return-void
.end method
.method public priority(IIIZ)V
.registers 5
return-void
.end method
.method public pushPromise(IILjava/util/List;)V
.registers 4
.annotation system Ldalvik/annotation/Signature;
value = {
"(II",
"Ljava/util/List<",
"Lcom/squareup/okhttp/internal/framed/Header;",
">;)V"
}
.end annotation
.line 1
iget-object p1, p0, Lcom/squareup/okhttp/internal/framed/FramedConnection$Reader;->this$0:Lcom/squareup/okhttp/internal/framed/FramedConnection;
# invokes: Lcom/squareup/okhttp/internal/framed/FramedConnection;->pushRequestLater(ILjava/util/List;)V
invoke-static {p1, p2, p3}, Lcom/squareup/okhttp/internal/framed/FramedConnection;->access$2400(Lcom/squareup/okhttp/internal/framed/FramedConnection;ILjava/util/List;)V
return-void
.end method
.method public rstStream(ILcom/squareup/okhttp/internal/framed/ErrorCode;)V
.registers 4
.line 1
iget-object v0, p0, Lcom/squareup/okhttp/internal/framed/FramedConnection$Reader;->this$0:Lcom/squareup/okhttp/internal/framed/FramedConnection;
# invokes: Lcom/squareup/okhttp/internal/framed/FramedConnection;->pushedStream(I)Z
invoke-static {v0, p1}, Lcom/squareup/okhttp/internal/framed/FramedConnection;->access$1100(Lcom/squareup/okhttp/internal/framed/FramedConnection;I)Z
move-result v0
if-eqz v0, :cond_e
.line 2
iget-object v0, p0, Lcom/squareup/okhttp/internal/framed/FramedConnection$Reader;->this$0:Lcom/squareup/okhttp/internal/framed/FramedConnection;
# invokes: Lcom/squareup/okhttp/internal/framed/FramedConnection;->pushResetLater(ILcom/squareup/okhttp/internal/framed/ErrorCode;)V
invoke-static {v0, p1, p2}, Lcom/squareup/okhttp/internal/framed/FramedConnection;->access$2000(Lcom/squareup/okhttp/internal/framed/FramedConnection;ILcom/squareup/okhttp/internal/framed/ErrorCode;)V
return-void
.line 3
:cond_e
iget-object v0, p0, Lcom/squareup/okhttp/internal/framed/FramedConnection$Reader;->this$0:Lcom/squareup/okhttp/internal/framed/FramedConnection;
invoke-virtual {v0, p1}, Lcom/squareup/okhttp/internal/framed/FramedConnection;->removeStream(I)Lcom/squareup/okhttp/internal/framed/FramedStream;
move-result-object p1
if-eqz p1, :cond_19
.line 4
invoke-virtual {p1, p2}, Lcom/squareup/okhttp/internal/framed/FramedStream;->receiveRstStream(Lcom/squareup/okhttp/internal/framed/ErrorCode;)V
:cond_19
return-void
.end method
.method public settings(ZLcom/squareup/okhttp/internal/framed/Settings;)V
.registers 9
.line 1
iget-object v0, p0, Lcom/squareup/okhttp/internal/framed/FramedConnection$Reader;->this$0:Lcom/squareup/okhttp/internal/framed/FramedConnection;
monitor-enter v0
.line 2
:try_start_3
iget-object v1, p0, Lcom/squareup/okhttp/internal/framed/FramedConnection$Reader;->this$0:Lcom/squareup/okhttp/internal/framed/FramedConnection;
iget-object v1, v1, Lcom/squareup/okhttp/internal/framed/FramedConnection;->peerSettings:Lcom/squareup/okhttp/internal/framed/Settings;
const/high16 v2, 0x10000
invoke-virtual {v1, v2}, Lcom/squareup/okhttp/internal/framed/Settings;->getInitialWindowSize(I)I
move-result v1
if-eqz p1, :cond_16
.line 3
iget-object p1, p0, Lcom/squareup/okhttp/internal/framed/FramedConnection$Reader;->this$0:Lcom/squareup/okhttp/internal/framed/FramedConnection;
iget-object p1, p1, Lcom/squareup/okhttp/internal/framed/FramedConnection;->peerSettings:Lcom/squareup/okhttp/internal/framed/Settings;
invoke-virtual {p1}, Lcom/squareup/okhttp/internal/framed/Settings;->clear()V
.line 4
:cond_16
iget-object p1, p0, Lcom/squareup/okhttp/internal/framed/FramedConnection$Reader;->this$0:Lcom/squareup/okhttp/internal/framed/FramedConnection;
iget-object p1, p1, Lcom/squareup/okhttp/internal/framed/FramedConnection;->peerSettings:Lcom/squareup/okhttp/internal/framed/Settings;
invoke-virtual {p1, p2}, Lcom/squareup/okhttp/internal/framed/Settings;->merge(Lcom/squareup/okhttp/internal/framed/Settings;)V
.line 5
iget-object p1, p0, Lcom/squareup/okhttp/internal/framed/FramedConnection$Reader;->this$0:Lcom/squareup/okhttp/internal/framed/FramedConnection;
invoke-virtual {p1}, Lcom/squareup/okhttp/internal/framed/FramedConnection;->getProtocol()Lcom/squareup/okhttp/Protocol;
move-result-object p1
sget-object v3, Lcom/squareup/okhttp/Protocol;->HTTP_2:Lcom/squareup/okhttp/Protocol;
if-ne p1, v3, :cond_2a
.line 6
invoke-direct {p0, p2}, Lcom/squareup/okhttp/internal/framed/FramedConnection$Reader;->ackSettingsLater(Lcom/squareup/okhttp/internal/framed/Settings;)V
.line 7
:cond_2a
iget-object p1, p0, Lcom/squareup/okhttp/internal/framed/FramedConnection$Reader;->this$0:Lcom/squareup/okhttp/internal/framed/FramedConnection;
iget-object p1, p1, Lcom/squareup/okhttp/internal/framed/FramedConnection;->peerSettings:Lcom/squareup/okhttp/internal/framed/Settings;
invoke-virtual {p1, v2}, Lcom/squareup/okhttp/internal/framed/Settings;->getInitialWindowSize(I)I
move-result p1
const/4 p2, -0x1
const-wide/16 v2, 0x0
const/4 v4, 0x0
if-eq p1, p2, :cond_79
if-eq p1, v1, :cond_79
sub-int/2addr p1, v1
int-to-long p1, p1
.line 8
iget-object v1, p0, Lcom/squareup/okhttp/internal/framed/FramedConnection$Reader;->this$0:Lcom/squareup/okhttp/internal/framed/FramedConnection;
# getter for: Lcom/squareup/okhttp/internal/framed/FramedConnection;->receivedInitialPeerSettings:Z
invoke-static {v1}, Lcom/squareup/okhttp/internal/framed/FramedConnection;->access$2100(Lcom/squareup/okhttp/internal/framed/FramedConnection;)Z
move-result v1
if-nez v1, :cond_4f
.line 9
iget-object v1, p0, Lcom/squareup/okhttp/internal/framed/FramedConnection$Reader;->this$0:Lcom/squareup/okhttp/internal/framed/FramedConnection;
invoke-virtual {v1, p1, p2}, Lcom/squareup/okhttp/internal/framed/FramedConnection;->addBytesToWriteWindow(J)V
.line 10
iget-object v1, p0, Lcom/squareup/okhttp/internal/framed/FramedConnection$Reader;->this$0:Lcom/squareup/okhttp/internal/framed/FramedConnection;
const/4 v5, 0x1
# setter for: Lcom/squareup/okhttp/internal/framed/FramedConnection;->receivedInitialPeerSettings:Z
invoke-static {v1, v5}, Lcom/squareup/okhttp/internal/framed/FramedConnection;->access$2102(Lcom/squareup/okhttp/internal/framed/FramedConnection;Z)Z
.line 11
:cond_4f
iget-object v1, p0, Lcom/squareup/okhttp/internal/framed/FramedConnection$Reader;->this$0:Lcom/squareup/okhttp/internal/framed/FramedConnection;
# getter for: Lcom/squareup/okhttp/internal/framed/FramedConnection;->streams:Ljava/util/Map;
invoke-static {v1}, Lcom/squareup/okhttp/internal/framed/FramedConnection;->access$1700(Lcom/squareup/okhttp/internal/framed/FramedConnection;)Ljava/util/Map;
move-result-object v1
invoke-interface {v1}, Ljava/util/Map;->isEmpty()Z
move-result v1
if-nez v1, :cond_7a
.line 12
iget-object v1, p0, Lcom/squareup/okhttp/internal/framed/FramedConnection$Reader;->this$0:Lcom/squareup/okhttp/internal/framed/FramedConnection;
# getter for: Lcom/squareup/okhttp/internal/framed/FramedConnection;->streams:Ljava/util/Map;
invoke-static {v1}, Lcom/squareup/okhttp/internal/framed/FramedConnection;->access$1700(Lcom/squareup/okhttp/internal/framed/FramedConnection;)Ljava/util/Map;
move-result-object v1
invoke-interface {v1}, Ljava/util/Map;->values()Ljava/util/Collection;
move-result-object v1
iget-object v4, p0, Lcom/squareup/okhttp/internal/framed/FramedConnection$Reader;->this$0:Lcom/squareup/okhttp/internal/framed/FramedConnection;
# getter for: Lcom/squareup/okhttp/internal/framed/FramedConnection;->streams:Ljava/util/Map;
invoke-static {v4}, Lcom/squareup/okhttp/internal/framed/FramedConnection;->access$1700(Lcom/squareup/okhttp/internal/framed/FramedConnection;)Ljava/util/Map;
move-result-object v4
invoke-interface {v4}, Ljava/util/Map;->size()I
move-result v4
new-array v4, v4, [Lcom/squareup/okhttp/internal/framed/FramedStream;
invoke-interface {v1, v4}, Ljava/util/Collection;->toArray([Ljava/lang/Object;)[Ljava/lang/Object;
move-result-object v1
move-object v4, v1
check-cast v4, [Lcom/squareup/okhttp/internal/framed/FramedStream;
goto :goto_7a
:cond_79
move-wide p1, v2
.line 13
:cond_7a
:goto_7a
monitor-exit v0
:try_end_7b
.catchall {:try_start_3 .. :try_end_7b} :catchall_93
if-eqz v4, :cond_92
cmp-long v0, p1, v2
if-eqz v0, :cond_92
.line 14
array-length v0, v4
const/4 v1, 0x0
:goto_83
if-ge v1, v0, :cond_92
aget-object v2, v4, v1
.line 15
monitor-enter v2
.line 16
:try_start_88
invoke-virtual {v2, p1, p2}, Lcom/squareup/okhttp/internal/framed/FramedStream;->addBytesToWriteWindow(J)V
.line 17
monitor-exit v2
add-int/lit8 v1, v1, 0x1
goto :goto_83
:catchall_8f
move-exception p1
monitor-exit v2
:try_end_91
.catchall {:try_start_88 .. :try_end_91} :catchall_8f
throw p1
:cond_92
return-void
:catchall_93
move-exception p1
.line 18
:try_start_94
monitor-exit v0
:try_end_95
.catchall {:try_start_94 .. :try_end_95} :catchall_93
goto :goto_97
:goto_96
throw p1
:goto_97
goto :goto_96
.end method
.method public windowUpdate(IJ)V
.registers 7
if-nez p1, :cond_16
.line 1
iget-object v0, p0, Lcom/squareup/okhttp/internal/framed/FramedConnection$Reader;->this$0:Lcom/squareup/okhttp/internal/framed/FramedConnection;
monitor-enter v0
.line 2
:try_start_5
iget-object p1, p0, Lcom/squareup/okhttp/internal/framed/FramedConnection$Reader;->this$0:Lcom/squareup/okhttp/internal/framed/FramedConnection;
iget-wide v1, p1, Lcom/squareup/okhttp/internal/framed/FramedConnection;->bytesLeftInWriteWindow:J
add-long/2addr v1, p2
iput-wide v1, p1, Lcom/squareup/okhttp/internal/framed/FramedConnection;->bytesLeftInWriteWindow:J
.line 3
iget-object p1, p0, Lcom/squareup/okhttp/internal/framed/FramedConnection$Reader;->this$0:Lcom/squareup/okhttp/internal/framed/FramedConnection;
invoke-virtual {p1}, Ljava/lang/Object;->notifyAll()V
.line 4
monitor-exit v0
goto :goto_27
:catchall_13
move-exception p1
monitor-exit v0
:try_end_15
.catchall {:try_start_5 .. :try_end_15} :catchall_13
throw p1
.line 5
:cond_16
iget-object v0, p0, Lcom/squareup/okhttp/internal/framed/FramedConnection$Reader;->this$0:Lcom/squareup/okhttp/internal/framed/FramedConnection;
invoke-virtual {v0, p1}, Lcom/squareup/okhttp/internal/framed/FramedConnection;->getStream(I)Lcom/squareup/okhttp/internal/framed/FramedStream;
move-result-object p1
if-eqz p1, :cond_27
.line 6
monitor-enter p1
.line 7
:try_start_1f
invoke-virtual {p1, p2, p3}, Lcom/squareup/okhttp/internal/framed/FramedStream;->addBytesToWriteWindow(J)V
.line 8
monitor-exit p1
goto :goto_27
:catchall_24
move-exception p2
monitor-exit p1
:try_end_26
.catchall {:try_start_1f .. :try_end_26} :catchall_24
throw p2
:cond_27
:goto_27
return-void
.end method