apkfuckery/com.discord/smali_classes2/okio/y.smali
2019-12-03 22:42:56 +01:00

256 lines
4.5 KiB
Smali

.class public Lokio/y;
.super Ljava/lang/Object;
.source "Timeout.kt"
# annotations
.annotation system Ldalvik/annotation/MemberClasses;
value = {
Lokio/y$a;
}
.end annotation
# static fields
.field public static final bCo:Lokio/y;
.field public static final bCp:Lokio/y$a;
# instance fields
.field private bCl:Z
.field private bCm:J
.field private bCn:J
# direct methods
.method static constructor <clinit>()V
.locals 2
new-instance v0, Lokio/y$a;
const/4 v1, 0x0
invoke-direct {v0, v1}, Lokio/y$a;-><init>(B)V
sput-object v0, Lokio/y;->bCp:Lokio/y$a;
new-instance v0, Lokio/y$b;
invoke-direct {v0}, Lokio/y$b;-><init>()V
check-cast v0, Lokio/y;
sput-object v0, Lokio/y;->bCo:Lokio/y;
return-void
.end method
.method public constructor <init>()V
.locals 0
invoke-direct {p0}, Ljava/lang/Object;-><init>()V
return-void
.end method
# virtual methods
.method public IB()J
.locals 2
iget-wide v0, p0, Lokio/y;->bCn:J
return-wide v0
.end method
.method public IC()Z
.locals 1
iget-boolean v0, p0, Lokio/y;->bCl:Z
return v0
.end method
.method public ID()J
.locals 2
iget-boolean v0, p0, Lokio/y;->bCl:Z
if-eqz v0, :cond_0
iget-wide v0, p0, Lokio/y;->bCm:J
return-wide v0
:cond_0
new-instance v0, Ljava/lang/IllegalStateException;
const-string v1, "No deadline"
invoke-virtual {v1}, Ljava/lang/Object;->toString()Ljava/lang/String;
move-result-object v1
invoke-direct {v0, v1}, Ljava/lang/IllegalStateException;-><init>(Ljava/lang/String;)V
check-cast v0, Ljava/lang/Throwable;
throw v0
.end method
.method public IE()Lokio/y;
.locals 2
const-wide/16 v0, 0x0
iput-wide v0, p0, Lokio/y;->bCn:J
return-object p0
.end method
.method public IF()Lokio/y;
.locals 1
const/4 v0, 0x0
iput-boolean v0, p0, Lokio/y;->bCl:Z
return-object p0
.end method
.method public IG()V
.locals 5
.annotation system Ldalvik/annotation/Throws;
value = {
Ljava/io/IOException;
}
.end annotation
invoke-static {}, Ljava/lang/Thread;->interrupted()Z
move-result v0
if-nez v0, :cond_2
iget-boolean v0, p0, Lokio/y;->bCl:Z
if-eqz v0, :cond_1
iget-wide v0, p0, Lokio/y;->bCm:J
invoke-static {}, Ljava/lang/System;->nanoTime()J
move-result-wide v2
sub-long/2addr v0, v2
const-wide/16 v2, 0x0
cmp-long v4, v0, v2
if-lez v4, :cond_0
goto :goto_0
:cond_0
new-instance v0, Ljava/io/InterruptedIOException;
const-string v1, "deadline reached"
invoke-direct {v0, v1}, Ljava/io/InterruptedIOException;-><init>(Ljava/lang/String;)V
check-cast v0, Ljava/lang/Throwable;
throw v0
:cond_1
:goto_0
return-void
:cond_2
invoke-static {}, Ljava/lang/Thread;->currentThread()Ljava/lang/Thread;
move-result-object v0
invoke-virtual {v0}, Ljava/lang/Thread;->interrupt()V
new-instance v0, Ljava/io/InterruptedIOException;
const-string v1, "interrupted"
invoke-direct {v0, v1}, Ljava/io/InterruptedIOException;-><init>(Ljava/lang/String;)V
check-cast v0, Ljava/lang/Throwable;
throw v0
.end method
.method public aM(J)Lokio/y;
.locals 1
const/4 v0, 0x1
iput-boolean v0, p0, Lokio/y;->bCl:Z
iput-wide p1, p0, Lokio/y;->bCm:J
return-object p0
.end method
.method public d(JLjava/util/concurrent/TimeUnit;)Lokio/y;
.locals 3
const-string v0, "unit"
invoke-static {p3, v0}, Lkotlin/jvm/internal/l;->checkParameterIsNotNull(Ljava/lang/Object;Ljava/lang/String;)V
const-wide/16 v0, 0x0
cmp-long v2, p1, v0
if-ltz v2, :cond_0
const/4 v0, 0x1
goto :goto_0
:cond_0
const/4 v0, 0x0
:goto_0
if-eqz v0, :cond_1
invoke-virtual {p3, p1, p2}, Ljava/util/concurrent/TimeUnit;->toNanos(J)J
move-result-wide p1
iput-wide p1, p0, Lokio/y;->bCn:J
return-object p0
:cond_1
invoke-static {p1, p2}, Ljava/lang/String;->valueOf(J)Ljava/lang/String;
move-result-object p1
const-string p2, "timeout < 0: "
invoke-virtual {p2, p1}, Ljava/lang/String;->concat(Ljava/lang/String;)Ljava/lang/String;
move-result-object p1
new-instance p2, Ljava/lang/IllegalArgumentException;
invoke-virtual {p1}, Ljava/lang/Object;->toString()Ljava/lang/String;
move-result-object p1
invoke-direct {p2, p1}, Ljava/lang/IllegalArgumentException;-><init>(Ljava/lang/String;)V
check-cast p2, Ljava/lang/Throwable;
throw p2
.end method