FramedStream$StreamTimeout.smali
.class Lcom/squareup/okhttp/internal/framed/FramedStream$StreamTimeout;
.super Lokio/AsyncTimeout;
.source "FramedStream.java"
# annotations
.annotation system Ldalvik/annotation/EnclosingClass;
value = Lcom/squareup/okhttp/internal/framed/FramedStream;
.end annotation
.annotation system Ldalvik/annotation/InnerClass;
accessFlags = 0x0
name = "StreamTimeout"
.end annotation
# instance fields
.field final synthetic this$0:Lcom/squareup/okhttp/internal/framed/FramedStream;
# direct methods
.method constructor <init>(Lcom/squareup/okhttp/internal/framed/FramedStream;)V
.registers 2
.line 1
iput-object p1, p0, Lcom/squareup/okhttp/internal/framed/FramedStream$StreamTimeout;->this$0:Lcom/squareup/okhttp/internal/framed/FramedStream;
invoke-direct {p0}, Lokio/AsyncTimeout;-><init>()V
return-void
.end method
# virtual methods
.method public exitAndThrowIfTimedOut()V
.registers 2
.annotation system Ldalvik/annotation/Throws;
value = {
Ljava/io/IOException;
}
.end annotation
.line 1
invoke-virtual {p0}, Lokio/AsyncTimeout;->exit()Z
move-result v0
if-nez v0, :cond_7
return-void
:cond_7
const/4 v0, 0x0
invoke-virtual {p0, v0}, Lcom/squareup/okhttp/internal/framed/FramedStream$StreamTimeout;->newTimeoutException(Ljava/io/IOException;)Ljava/io/IOException;
move-result-object v0
throw v0
.end method
.method protected newTimeoutException(Ljava/io/IOException;)Ljava/io/IOException;
.registers 4
.line 1
new-instance v0, Ljava/net/SocketTimeoutException;
const-string v1, "timeout"
invoke-direct {v0, v1}, Ljava/net/SocketTimeoutException;-><init>(Ljava/lang/String;)V
if-eqz p1, :cond_c
.line 2
invoke-virtual {v0, p1}, Ljava/net/SocketTimeoutException;->initCause(Ljava/lang/Throwable;)Ljava/lang/Throwable;
:cond_c
return-object v0
.end method
.method protected timedOut()V
.registers 3
.line 1
iget-object v0, p0, Lcom/squareup/okhttp/internal/framed/FramedStream$StreamTimeout;->this$0:Lcom/squareup/okhttp/internal/framed/FramedStream;
sget-object v1, Lcom/squareup/okhttp/internal/framed/ErrorCode;->CANCEL:Lcom/squareup/okhttp/internal/framed/ErrorCode;
invoke-virtual {v0, v1}, Lcom/squareup/okhttp/internal/framed/FramedStream;->closeLater(Lcom/squareup/okhttp/internal/framed/ErrorCode;)V
return-void
.end method