apkfuckery/com.discord/smali/a/e.smali

213 lines
4 KiB
Smali
Raw Normal View History

2019-02-04 20:08:30 +00:00
.class public final La/e;
.super Ljava/lang/Object;
2019-02-04 20:29:01 +00:00
.source "CancellationTokenSource.java"
2019-02-04 20:08:30 +00:00
# interfaces
.implements Ljava/io/Closeable;
# instance fields
2019-02-21 02:16:48 +00:00
.field final bl:Ljava/util/List;
2019-02-04 20:08:30 +00:00
.annotation system Ldalvik/annotation/Signature;
value = {
"Ljava/util/List<",
"La/d;",
">;"
}
.end annotation
.end field
2019-02-21 02:16:48 +00:00
.field private bm:Ljava/util/concurrent/ScheduledFuture;
2019-02-04 20:08:30 +00:00
.annotation system Ldalvik/annotation/Signature;
value = {
"Ljava/util/concurrent/ScheduledFuture<",
"*>;"
}
.end annotation
.end field
2019-02-21 02:16:48 +00:00
.field private bn:Z
2019-02-04 20:08:30 +00:00
.field private closed:Z
.field final lock:Ljava/lang/Object;
# virtual methods
.method public final close()V
.locals 4
iget-object v0, p0, La/e;->lock:Ljava/lang/Object;
monitor-enter v0
:try_start_0
iget-boolean v1, p0, La/e;->closed:Z
if-eqz v1, :cond_0
monitor-exit v0
return-void
:cond_0
2019-02-21 02:16:48 +00:00
iget-object v1, p0, La/e;->bm:Ljava/util/concurrent/ScheduledFuture;
2019-02-04 20:08:30 +00:00
const/4 v2, 0x1
if-eqz v1, :cond_1
2019-02-21 02:16:48 +00:00
iget-object v1, p0, La/e;->bm:Ljava/util/concurrent/ScheduledFuture;
2019-02-04 20:08:30 +00:00
invoke-interface {v1, v2}, Ljava/util/concurrent/ScheduledFuture;->cancel(Z)Z
const/4 v1, 0x0
2019-02-21 02:16:48 +00:00
iput-object v1, p0, La/e;->bm:Ljava/util/concurrent/ScheduledFuture;
2019-02-04 20:08:30 +00:00
:cond_1
2019-02-21 02:16:48 +00:00
iget-object v1, p0, La/e;->bl:Ljava/util/List;
2019-02-04 20:08:30 +00:00
invoke-interface {v1}, Ljava/util/List;->iterator()Ljava/util/Iterator;
move-result-object v1
:goto_0
invoke-interface {v1}, Ljava/util/Iterator;->hasNext()Z
move-result v3
if-eqz v3, :cond_2
invoke-interface {v1}, Ljava/util/Iterator;->next()Ljava/lang/Object;
move-result-object v3
check-cast v3, La/d;
invoke-virtual {v3}, La/d;->close()V
goto :goto_0
:cond_2
2019-02-21 02:16:48 +00:00
iget-object v1, p0, La/e;->bl:Ljava/util/List;
2019-02-04 20:08:30 +00:00
invoke-interface {v1}, Ljava/util/List;->clear()V
iput-boolean v2, p0, La/e;->closed:Z
monitor-exit v0
return-void
:catchall_0
move-exception v1
monitor-exit v0
:try_end_0
.catchall {:try_start_0 .. :try_end_0} :catchall_0
throw v1
2019-02-04 20:29:01 +00:00
return-void
2019-02-04 20:08:30 +00:00
.end method
.method public final t()Z
.locals 2
iget-object v0, p0, La/e;->lock:Ljava/lang/Object;
monitor-enter v0
:try_start_0
invoke-virtual {p0}, La/e;->u()V
2019-02-21 02:16:48 +00:00
iget-boolean v1, p0, La/e;->bn:Z
2019-02-04 20:08:30 +00:00
monitor-exit v0
return v1
:catchall_0
move-exception v1
monitor-exit v0
:try_end_0
.catchall {:try_start_0 .. :try_end_0} :catchall_0
throw v1
.end method
.method public final toString()Ljava/lang/String;
.locals 5
sget-object v0, Ljava/util/Locale;->US:Ljava/util/Locale;
const-string v1, "%s@%s[cancellationRequested=%s]"
const/4 v2, 0x3
new-array v2, v2, [Ljava/lang/Object;
invoke-virtual {p0}, Ljava/lang/Object;->getClass()Ljava/lang/Class;
move-result-object v3
invoke-virtual {v3}, Ljava/lang/Class;->getName()Ljava/lang/String;
move-result-object v3
const/4 v4, 0x0
aput-object v3, v2, v4
invoke-virtual {p0}, Ljava/lang/Object;->hashCode()I
move-result v3
invoke-static {v3}, Ljava/lang/Integer;->toHexString(I)Ljava/lang/String;
move-result-object v3
const/4 v4, 0x1
aput-object v3, v2, v4
invoke-virtual {p0}, La/e;->t()Z
move-result v3
invoke-static {v3}, Ljava/lang/Boolean;->toString(Z)Ljava/lang/String;
move-result-object v3
const/4 v4, 0x2
aput-object v3, v2, v4
invoke-static {v0, v1, v2}, Ljava/lang/String;->format(Ljava/util/Locale;Ljava/lang/String;[Ljava/lang/Object;)Ljava/lang/String;
move-result-object v0
return-object v0
.end method
.method final u()V
.locals 2
iget-boolean v0, p0, La/e;->closed:Z
if-nez v0, :cond_0
return-void
:cond_0
new-instance v0, Ljava/lang/IllegalStateException;
const-string v1, "Object already closed"
invoke-direct {v0, v1}, Ljava/lang/IllegalStateException;-><init>(Ljava/lang/String;)V
throw v0
.end method