2019-07-24 11:27:29 +00:00
|
|
|
.class public abstract Landroidx/work/impl/utils/futures/AbstractFuture;
|
|
|
|
.super Ljava/lang/Object;
|
|
|
|
.source "AbstractFuture.java"
|
|
|
|
|
|
|
|
# interfaces
|
|
|
|
.implements Lcom/google/a/a/a/a;
|
|
|
|
|
|
|
|
|
|
|
|
# annotations
|
|
|
|
.annotation system Ldalvik/annotation/MemberClasses;
|
|
|
|
value = {
|
|
|
|
Landroidx/work/impl/utils/futures/AbstractFuture$SynchronizedHelper;,
|
|
|
|
Landroidx/work/impl/utils/futures/AbstractFuture$SafeAtomicHelper;,
|
|
|
|
Landroidx/work/impl/utils/futures/AbstractFuture$AtomicHelper;,
|
|
|
|
Landroidx/work/impl/utils/futures/AbstractFuture$SetFuture;,
|
|
|
|
Landroidx/work/impl/utils/futures/AbstractFuture$Cancellation;,
|
|
|
|
Landroidx/work/impl/utils/futures/AbstractFuture$Failure;,
|
|
|
|
Landroidx/work/impl/utils/futures/AbstractFuture$Listener;,
|
|
|
|
Landroidx/work/impl/utils/futures/AbstractFuture$Waiter;
|
|
|
|
}
|
|
|
|
.end annotation
|
|
|
|
|
|
|
|
.annotation system Ldalvik/annotation/Signature;
|
|
|
|
value = {
|
|
|
|
"<V:",
|
|
|
|
"Ljava/lang/Object;",
|
|
|
|
">",
|
|
|
|
"Ljava/lang/Object;",
|
|
|
|
"Lcom/google/a/a/a/a<",
|
|
|
|
"TV;>;"
|
|
|
|
}
|
|
|
|
.end annotation
|
|
|
|
|
|
|
|
|
|
|
|
# static fields
|
|
|
|
.field static final ATOMIC_HELPER:Landroidx/work/impl/utils/futures/AbstractFuture$AtomicHelper;
|
|
|
|
|
|
|
|
.field static final GENERATE_CANCELLATION_CAUSES:Z
|
|
|
|
|
|
|
|
.field private static final NULL:Ljava/lang/Object;
|
|
|
|
|
|
|
|
.field private static final SPIN_THRESHOLD_NANOS:J = 0x3e8L
|
|
|
|
|
|
|
|
.field private static final log:Ljava/util/logging/Logger;
|
|
|
|
|
|
|
|
|
|
|
|
# instance fields
|
|
|
|
.field volatile listeners:Landroidx/work/impl/utils/futures/AbstractFuture$Listener;
|
|
|
|
|
|
|
|
.field volatile value:Ljava/lang/Object;
|
|
|
|
|
|
|
|
.field volatile waiters:Landroidx/work/impl/utils/futures/AbstractFuture$Waiter;
|
|
|
|
|
|
|
|
|
|
|
|
# direct methods
|
|
|
|
.method static constructor <clinit>()V
|
|
|
|
.locals 8
|
|
|
|
|
2019-08-30 20:04:20 +00:00
|
|
|
const-class v0, Landroidx/work/impl/utils/futures/AbstractFuture;
|
2019-07-24 11:27:29 +00:00
|
|
|
|
2019-08-30 20:04:20 +00:00
|
|
|
const-string v1, "guava.concurrent.generate_cancellation_cause"
|
2019-07-24 11:27:29 +00:00
|
|
|
|
2019-08-30 20:04:20 +00:00
|
|
|
const-string v2, "false"
|
2019-07-24 11:27:29 +00:00
|
|
|
|
2019-08-30 20:04:20 +00:00
|
|
|
invoke-static {v1, v2}, Ljava/lang/System;->getProperty(Ljava/lang/String;Ljava/lang/String;)Ljava/lang/String;
|
2019-07-24 11:27:29 +00:00
|
|
|
|
2019-08-30 20:04:20 +00:00
|
|
|
move-result-object v1
|
2019-07-24 11:27:29 +00:00
|
|
|
|
2019-08-30 20:04:20 +00:00
|
|
|
invoke-static {v1}, Ljava/lang/Boolean;->parseBoolean(Ljava/lang/String;)Z
|
2019-07-24 11:27:29 +00:00
|
|
|
|
2019-08-30 20:04:20 +00:00
|
|
|
move-result v1
|
2019-07-24 11:27:29 +00:00
|
|
|
|
2019-08-30 20:04:20 +00:00
|
|
|
sput-boolean v1, Landroidx/work/impl/utils/futures/AbstractFuture;->GENERATE_CANCELLATION_CAUSES:Z
|
2019-07-24 11:27:29 +00:00
|
|
|
|
|
|
|
invoke-virtual {v0}, Ljava/lang/Class;->getName()Ljava/lang/String;
|
|
|
|
|
2019-08-30 20:04:20 +00:00
|
|
|
move-result-object v1
|
2019-07-24 11:27:29 +00:00
|
|
|
|
2019-08-30 20:04:20 +00:00
|
|
|
invoke-static {v1}, Ljava/util/logging/Logger;->getLogger(Ljava/lang/String;)Ljava/util/logging/Logger;
|
2019-07-24 11:27:29 +00:00
|
|
|
|
2019-08-30 20:04:20 +00:00
|
|
|
move-result-object v1
|
2019-07-24 11:27:29 +00:00
|
|
|
|
2019-08-30 20:04:20 +00:00
|
|
|
sput-object v1, Landroidx/work/impl/utils/futures/AbstractFuture;->log:Ljava/util/logging/Logger;
|
2019-07-24 11:27:29 +00:00
|
|
|
|
|
|
|
:try_start_0
|
2019-08-30 20:04:20 +00:00
|
|
|
new-instance v1, Landroidx/work/impl/utils/futures/AbstractFuture$SafeAtomicHelper;
|
2019-07-24 11:27:29 +00:00
|
|
|
|
2019-08-30 20:04:20 +00:00
|
|
|
const-class v2, Landroidx/work/impl/utils/futures/AbstractFuture$Waiter;
|
2019-07-24 11:27:29 +00:00
|
|
|
|
2019-08-30 20:04:20 +00:00
|
|
|
const-class v3, Ljava/lang/Thread;
|
2019-07-24 11:27:29 +00:00
|
|
|
|
2019-08-30 20:04:20 +00:00
|
|
|
const-string v4, "thread"
|
2019-07-24 11:27:29 +00:00
|
|
|
|
2019-08-30 20:04:20 +00:00
|
|
|
invoke-static {v2, v3, v4}, Ljava/util/concurrent/atomic/AtomicReferenceFieldUpdater;->newUpdater(Ljava/lang/Class;Ljava/lang/Class;Ljava/lang/String;)Ljava/util/concurrent/atomic/AtomicReferenceFieldUpdater;
|
2019-07-24 11:27:29 +00:00
|
|
|
|
2019-08-30 20:04:20 +00:00
|
|
|
move-result-object v3
|
2019-07-24 11:27:29 +00:00
|
|
|
|
2019-08-30 20:04:20 +00:00
|
|
|
const-class v2, Landroidx/work/impl/utils/futures/AbstractFuture$Waiter;
|
2019-07-24 11:27:29 +00:00
|
|
|
|
2019-08-30 20:04:20 +00:00
|
|
|
const-class v4, Landroidx/work/impl/utils/futures/AbstractFuture$Waiter;
|
2019-07-24 11:27:29 +00:00
|
|
|
|
2019-08-30 20:04:20 +00:00
|
|
|
const-string v5, "next"
|
2019-07-24 11:27:29 +00:00
|
|
|
|
2019-08-30 20:04:20 +00:00
|
|
|
invoke-static {v2, v4, v5}, Ljava/util/concurrent/atomic/AtomicReferenceFieldUpdater;->newUpdater(Ljava/lang/Class;Ljava/lang/Class;Ljava/lang/String;)Ljava/util/concurrent/atomic/AtomicReferenceFieldUpdater;
|
2019-07-24 11:27:29 +00:00
|
|
|
|
2019-08-30 20:04:20 +00:00
|
|
|
move-result-object v4
|
2019-07-24 11:27:29 +00:00
|
|
|
|
2019-08-30 20:04:20 +00:00
|
|
|
const-class v2, Landroidx/work/impl/utils/futures/AbstractFuture$Waiter;
|
2019-07-24 11:27:29 +00:00
|
|
|
|
|
|
|
const-string v5, "waiters"
|
|
|
|
|
2019-08-30 20:04:20 +00:00
|
|
|
invoke-static {v0, v2, v5}, Ljava/util/concurrent/atomic/AtomicReferenceFieldUpdater;->newUpdater(Ljava/lang/Class;Ljava/lang/Class;Ljava/lang/String;)Ljava/util/concurrent/atomic/AtomicReferenceFieldUpdater;
|
2019-07-24 11:27:29 +00:00
|
|
|
|
2019-08-30 20:04:20 +00:00
|
|
|
move-result-object v5
|
2019-07-24 11:27:29 +00:00
|
|
|
|
2019-08-30 20:04:20 +00:00
|
|
|
const-class v2, Landroidx/work/impl/utils/futures/AbstractFuture$Listener;
|
2019-07-24 11:27:29 +00:00
|
|
|
|
|
|
|
const-string v6, "listeners"
|
|
|
|
|
2019-08-30 20:04:20 +00:00
|
|
|
invoke-static {v0, v2, v6}, Ljava/util/concurrent/atomic/AtomicReferenceFieldUpdater;->newUpdater(Ljava/lang/Class;Ljava/lang/Class;Ljava/lang/String;)Ljava/util/concurrent/atomic/AtomicReferenceFieldUpdater;
|
2019-07-24 11:27:29 +00:00
|
|
|
|
2019-08-30 20:04:20 +00:00
|
|
|
move-result-object v6
|
2019-07-24 11:27:29 +00:00
|
|
|
|
2019-08-30 20:04:20 +00:00
|
|
|
const-class v2, Ljava/lang/Object;
|
2019-07-24 11:27:29 +00:00
|
|
|
|
|
|
|
const-string v7, "value"
|
|
|
|
|
2019-08-30 20:04:20 +00:00
|
|
|
invoke-static {v0, v2, v7}, Ljava/util/concurrent/atomic/AtomicReferenceFieldUpdater;->newUpdater(Ljava/lang/Class;Ljava/lang/Class;Ljava/lang/String;)Ljava/util/concurrent/atomic/AtomicReferenceFieldUpdater;
|
2019-07-24 11:27:29 +00:00
|
|
|
|
2019-08-30 20:04:20 +00:00
|
|
|
move-result-object v7
|
2019-07-24 11:27:29 +00:00
|
|
|
|
2019-08-30 20:04:20 +00:00
|
|
|
move-object v2, v1
|
2019-07-24 11:27:29 +00:00
|
|
|
|
2019-08-30 20:04:20 +00:00
|
|
|
invoke-direct/range {v2 .. v7}, Landroidx/work/impl/utils/futures/AbstractFuture$SafeAtomicHelper;-><init>(Ljava/util/concurrent/atomic/AtomicReferenceFieldUpdater;Ljava/util/concurrent/atomic/AtomicReferenceFieldUpdater;Ljava/util/concurrent/atomic/AtomicReferenceFieldUpdater;Ljava/util/concurrent/atomic/AtomicReferenceFieldUpdater;Ljava/util/concurrent/atomic/AtomicReferenceFieldUpdater;)V
|
2019-07-24 11:27:29 +00:00
|
|
|
:try_end_0
|
2019-08-30 20:04:20 +00:00
|
|
|
.catchall {:try_start_0 .. :try_end_0} :catchall_0
|
2019-07-24 11:27:29 +00:00
|
|
|
|
2019-08-30 20:04:20 +00:00
|
|
|
const/4 v0, 0x0
|
2019-07-24 11:27:29 +00:00
|
|
|
|
|
|
|
goto :goto_0
|
|
|
|
|
2019-08-30 20:04:20 +00:00
|
|
|
:catchall_0
|
2019-07-24 11:27:29 +00:00
|
|
|
move-exception v0
|
|
|
|
|
2019-08-30 20:04:20 +00:00
|
|
|
new-instance v1, Landroidx/work/impl/utils/futures/AbstractFuture$SynchronizedHelper;
|
2019-07-24 11:27:29 +00:00
|
|
|
|
2019-08-30 20:04:20 +00:00
|
|
|
invoke-direct {v1}, Landroidx/work/impl/utils/futures/AbstractFuture$SynchronizedHelper;-><init>()V
|
2019-07-24 11:27:29 +00:00
|
|
|
|
|
|
|
:goto_0
|
2019-08-30 20:04:20 +00:00
|
|
|
sput-object v1, Landroidx/work/impl/utils/futures/AbstractFuture;->ATOMIC_HELPER:Landroidx/work/impl/utils/futures/AbstractFuture$AtomicHelper;
|
2019-07-24 11:27:29 +00:00
|
|
|
|
2019-08-30 20:04:20 +00:00
|
|
|
const-class v1, Ljava/util/concurrent/locks/LockSupport;
|
2019-07-24 11:27:29 +00:00
|
|
|
|
2019-08-30 20:04:20 +00:00
|
|
|
if-eqz v0, :cond_0
|
2019-07-24 11:27:29 +00:00
|
|
|
|
2019-08-30 20:04:20 +00:00
|
|
|
sget-object v1, Landroidx/work/impl/utils/futures/AbstractFuture;->log:Ljava/util/logging/Logger;
|
2019-07-24 11:27:29 +00:00
|
|
|
|
|
|
|
sget-object v2, Ljava/util/logging/Level;->SEVERE:Ljava/util/logging/Level;
|
|
|
|
|
|
|
|
const-string v3, "SafeAtomicHelper is broken!"
|
|
|
|
|
2019-08-30 20:04:20 +00:00
|
|
|
invoke-virtual {v1, v2, v3, v0}, Ljava/util/logging/Logger;->log(Ljava/util/logging/Level;Ljava/lang/String;Ljava/lang/Throwable;)V
|
2019-07-24 11:27:29 +00:00
|
|
|
|
|
|
|
:cond_0
|
|
|
|
new-instance v0, Ljava/lang/Object;
|
|
|
|
|
|
|
|
invoke-direct {v0}, Ljava/lang/Object;-><init>()V
|
|
|
|
|
|
|
|
sput-object v0, Landroidx/work/impl/utils/futures/AbstractFuture;->NULL:Ljava/lang/Object;
|
|
|
|
|
|
|
|
return-void
|
|
|
|
.end method
|
|
|
|
|
|
|
|
.method protected constructor <init>()V
|
|
|
|
.locals 0
|
|
|
|
|
|
|
|
invoke-direct {p0}, Ljava/lang/Object;-><init>()V
|
|
|
|
|
|
|
|
return-void
|
|
|
|
.end method
|
|
|
|
|
|
|
|
.method private addDoneString(Ljava/lang/StringBuilder;)V
|
|
|
|
.locals 3
|
|
|
|
|
|
|
|
const-string v0, "]"
|
|
|
|
|
|
|
|
:try_start_0
|
|
|
|
invoke-static {p0}, Landroidx/work/impl/utils/futures/AbstractFuture;->getUninterruptibly(Ljava/util/concurrent/Future;)Ljava/lang/Object;
|
|
|
|
|
|
|
|
move-result-object v1
|
|
|
|
|
|
|
|
const-string v2, "SUCCESS, result=["
|
|
|
|
|
|
|
|
invoke-virtual {p1, v2}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;
|
|
|
|
|
|
|
|
invoke-direct {p0, v1}, Landroidx/work/impl/utils/futures/AbstractFuture;->userObjectToString(Ljava/lang/Object;)Ljava/lang/String;
|
|
|
|
|
|
|
|
move-result-object v1
|
|
|
|
|
|
|
|
invoke-virtual {p1, v1}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;
|
|
|
|
|
|
|
|
invoke-virtual {p1, v0}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;
|
|
|
|
:try_end_0
|
|
|
|
.catch Ljava/util/concurrent/ExecutionException; {:try_start_0 .. :try_end_0} :catch_2
|
|
|
|
.catch Ljava/util/concurrent/CancellationException; {:try_start_0 .. :try_end_0} :catch_1
|
|
|
|
.catch Ljava/lang/RuntimeException; {:try_start_0 .. :try_end_0} :catch_0
|
|
|
|
|
|
|
|
return-void
|
|
|
|
|
|
|
|
:catch_0
|
|
|
|
move-exception v0
|
|
|
|
|
|
|
|
const-string v1, "UNKNOWN, cause=["
|
|
|
|
|
|
|
|
invoke-virtual {p1, v1}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;
|
|
|
|
|
|
|
|
invoke-virtual {v0}, Ljava/lang/Object;->getClass()Ljava/lang/Class;
|
|
|
|
|
|
|
|
move-result-object v0
|
|
|
|
|
|
|
|
invoke-virtual {p1, v0}, Ljava/lang/StringBuilder;->append(Ljava/lang/Object;)Ljava/lang/StringBuilder;
|
|
|
|
|
|
|
|
const-string v0, " thrown from get()]"
|
|
|
|
|
|
|
|
invoke-virtual {p1, v0}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;
|
|
|
|
|
|
|
|
return-void
|
|
|
|
|
|
|
|
:catch_1
|
|
|
|
const-string v0, "CANCELLED"
|
|
|
|
|
|
|
|
invoke-virtual {p1, v0}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;
|
|
|
|
|
|
|
|
return-void
|
|
|
|
|
|
|
|
:catch_2
|
|
|
|
move-exception v1
|
|
|
|
|
|
|
|
const-string v2, "FAILURE, cause=["
|
|
|
|
|
|
|
|
invoke-virtual {p1, v2}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;
|
|
|
|
|
|
|
|
invoke-virtual {v1}, Ljava/util/concurrent/ExecutionException;->getCause()Ljava/lang/Throwable;
|
|
|
|
|
|
|
|
move-result-object v1
|
|
|
|
|
|
|
|
invoke-virtual {p1, v1}, Ljava/lang/StringBuilder;->append(Ljava/lang/Object;)Ljava/lang/StringBuilder;
|
|
|
|
|
|
|
|
invoke-virtual {p1, v0}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;
|
|
|
|
|
|
|
|
return-void
|
|
|
|
.end method
|
|
|
|
|
|
|
|
.method private static cancellationExceptionWithCause(Ljava/lang/String;Ljava/lang/Throwable;)Ljava/util/concurrent/CancellationException;
|
|
|
|
.locals 1
|
|
|
|
|
|
|
|
new-instance v0, Ljava/util/concurrent/CancellationException;
|
|
|
|
|
|
|
|
invoke-direct {v0, p0}, Ljava/util/concurrent/CancellationException;-><init>(Ljava/lang/String;)V
|
|
|
|
|
|
|
|
invoke-virtual {v0, p1}, Ljava/util/concurrent/CancellationException;->initCause(Ljava/lang/Throwable;)Ljava/lang/Throwable;
|
|
|
|
|
|
|
|
return-object v0
|
|
|
|
.end method
|
|
|
|
|
|
|
|
.method static checkNotNull(Ljava/lang/Object;)Ljava/lang/Object;
|
|
|
|
.locals 0
|
|
|
|
.annotation system Ldalvik/annotation/Signature;
|
|
|
|
value = {
|
|
|
|
"<T:",
|
|
|
|
"Ljava/lang/Object;",
|
|
|
|
">(TT;)TT;"
|
|
|
|
}
|
|
|
|
.end annotation
|
|
|
|
|
|
|
|
if-eqz p0, :cond_0
|
|
|
|
|
|
|
|
return-object p0
|
|
|
|
|
|
|
|
:cond_0
|
|
|
|
new-instance p0, Ljava/lang/NullPointerException;
|
|
|
|
|
|
|
|
invoke-direct {p0}, Ljava/lang/NullPointerException;-><init>()V
|
|
|
|
|
|
|
|
throw p0
|
|
|
|
.end method
|
|
|
|
|
|
|
|
.method private clearListeners(Landroidx/work/impl/utils/futures/AbstractFuture$Listener;)Landroidx/work/impl/utils/futures/AbstractFuture$Listener;
|
|
|
|
.locals 4
|
|
|
|
|
|
|
|
:cond_0
|
|
|
|
iget-object v0, p0, Landroidx/work/impl/utils/futures/AbstractFuture;->listeners:Landroidx/work/impl/utils/futures/AbstractFuture$Listener;
|
|
|
|
|
|
|
|
sget-object v1, Landroidx/work/impl/utils/futures/AbstractFuture;->ATOMIC_HELPER:Landroidx/work/impl/utils/futures/AbstractFuture$AtomicHelper;
|
|
|
|
|
|
|
|
sget-object v2, Landroidx/work/impl/utils/futures/AbstractFuture$Listener;->TOMBSTONE:Landroidx/work/impl/utils/futures/AbstractFuture$Listener;
|
|
|
|
|
|
|
|
invoke-virtual {v1, p0, v0, v2}, Landroidx/work/impl/utils/futures/AbstractFuture$AtomicHelper;->casListeners(Landroidx/work/impl/utils/futures/AbstractFuture;Landroidx/work/impl/utils/futures/AbstractFuture$Listener;Landroidx/work/impl/utils/futures/AbstractFuture$Listener;)Z
|
|
|
|
|
|
|
|
move-result v1
|
|
|
|
|
|
|
|
if-eqz v1, :cond_0
|
|
|
|
|
|
|
|
move-object v3, v0
|
|
|
|
|
|
|
|
move-object v0, p1
|
|
|
|
|
|
|
|
move-object p1, v3
|
|
|
|
|
|
|
|
:goto_0
|
|
|
|
if-eqz p1, :cond_1
|
|
|
|
|
|
|
|
iget-object v1, p1, Landroidx/work/impl/utils/futures/AbstractFuture$Listener;->next:Landroidx/work/impl/utils/futures/AbstractFuture$Listener;
|
|
|
|
|
|
|
|
iput-object v0, p1, Landroidx/work/impl/utils/futures/AbstractFuture$Listener;->next:Landroidx/work/impl/utils/futures/AbstractFuture$Listener;
|
|
|
|
|
|
|
|
move-object v0, p1
|
|
|
|
|
|
|
|
move-object p1, v1
|
|
|
|
|
|
|
|
goto :goto_0
|
|
|
|
|
|
|
|
:cond_1
|
|
|
|
return-object v0
|
|
|
|
.end method
|
|
|
|
|
|
|
|
.method static complete(Landroidx/work/impl/utils/futures/AbstractFuture;)V
|
|
|
|
.locals 4
|
|
|
|
.annotation system Ldalvik/annotation/Signature;
|
|
|
|
value = {
|
|
|
|
"(",
|
|
|
|
"Landroidx/work/impl/utils/futures/AbstractFuture<",
|
|
|
|
"*>;)V"
|
|
|
|
}
|
|
|
|
.end annotation
|
|
|
|
|
|
|
|
const/4 v0, 0x0
|
|
|
|
|
|
|
|
:cond_0
|
|
|
|
invoke-direct {p0}, Landroidx/work/impl/utils/futures/AbstractFuture;->releaseWaiters()V
|
|
|
|
|
|
|
|
invoke-virtual {p0}, Landroidx/work/impl/utils/futures/AbstractFuture;->afterDone()V
|
|
|
|
|
|
|
|
invoke-direct {p0, v0}, Landroidx/work/impl/utils/futures/AbstractFuture;->clearListeners(Landroidx/work/impl/utils/futures/AbstractFuture$Listener;)Landroidx/work/impl/utils/futures/AbstractFuture$Listener;
|
|
|
|
|
|
|
|
move-result-object p0
|
|
|
|
|
|
|
|
:goto_0
|
|
|
|
if-eqz p0, :cond_3
|
|
|
|
|
|
|
|
iget-object v0, p0, Landroidx/work/impl/utils/futures/AbstractFuture$Listener;->next:Landroidx/work/impl/utils/futures/AbstractFuture$Listener;
|
|
|
|
|
|
|
|
iget-object v1, p0, Landroidx/work/impl/utils/futures/AbstractFuture$Listener;->task:Ljava/lang/Runnable;
|
|
|
|
|
|
|
|
instance-of v2, v1, Landroidx/work/impl/utils/futures/AbstractFuture$SetFuture;
|
|
|
|
|
|
|
|
if-eqz v2, :cond_1
|
|
|
|
|
|
|
|
check-cast v1, Landroidx/work/impl/utils/futures/AbstractFuture$SetFuture;
|
|
|
|
|
|
|
|
iget-object p0, v1, Landroidx/work/impl/utils/futures/AbstractFuture$SetFuture;->owner:Landroidx/work/impl/utils/futures/AbstractFuture;
|
|
|
|
|
|
|
|
iget-object v2, p0, Landroidx/work/impl/utils/futures/AbstractFuture;->value:Ljava/lang/Object;
|
|
|
|
|
|
|
|
if-ne v2, v1, :cond_2
|
|
|
|
|
|
|
|
iget-object v2, v1, Landroidx/work/impl/utils/futures/AbstractFuture$SetFuture;->future:Lcom/google/a/a/a/a;
|
|
|
|
|
|
|
|
invoke-static {v2}, Landroidx/work/impl/utils/futures/AbstractFuture;->getFutureValue(Lcom/google/a/a/a/a;)Ljava/lang/Object;
|
|
|
|
|
|
|
|
move-result-object v2
|
|
|
|
|
|
|
|
sget-object v3, Landroidx/work/impl/utils/futures/AbstractFuture;->ATOMIC_HELPER:Landroidx/work/impl/utils/futures/AbstractFuture$AtomicHelper;
|
|
|
|
|
|
|
|
invoke-virtual {v3, p0, v1, v2}, Landroidx/work/impl/utils/futures/AbstractFuture$AtomicHelper;->casValue(Landroidx/work/impl/utils/futures/AbstractFuture;Ljava/lang/Object;Ljava/lang/Object;)Z
|
|
|
|
|
|
|
|
move-result v1
|
|
|
|
|
|
|
|
if-nez v1, :cond_0
|
|
|
|
|
|
|
|
goto :goto_1
|
|
|
|
|
|
|
|
:cond_1
|
|
|
|
iget-object p0, p0, Landroidx/work/impl/utils/futures/AbstractFuture$Listener;->executor:Ljava/util/concurrent/Executor;
|
|
|
|
|
|
|
|
invoke-static {v1, p0}, Landroidx/work/impl/utils/futures/AbstractFuture;->executeListener(Ljava/lang/Runnable;Ljava/util/concurrent/Executor;)V
|
|
|
|
|
|
|
|
:cond_2
|
|
|
|
:goto_1
|
|
|
|
move-object p0, v0
|
|
|
|
|
|
|
|
goto :goto_0
|
|
|
|
|
|
|
|
:cond_3
|
|
|
|
return-void
|
|
|
|
.end method
|
|
|
|
|
|
|
|
.method private static executeListener(Ljava/lang/Runnable;Ljava/util/concurrent/Executor;)V
|
|
|
|
.locals 5
|
|
|
|
|
|
|
|
:try_start_0
|
|
|
|
invoke-interface {p1, p0}, Ljava/util/concurrent/Executor;->execute(Ljava/lang/Runnable;)V
|
|
|
|
:try_end_0
|
|
|
|
.catch Ljava/lang/RuntimeException; {:try_start_0 .. :try_end_0} :catch_0
|
|
|
|
|
|
|
|
return-void
|
|
|
|
|
|
|
|
:catch_0
|
|
|
|
move-exception v0
|
|
|
|
|
|
|
|
sget-object v1, Landroidx/work/impl/utils/futures/AbstractFuture;->log:Ljava/util/logging/Logger;
|
|
|
|
|
|
|
|
sget-object v2, Ljava/util/logging/Level;->SEVERE:Ljava/util/logging/Level;
|
|
|
|
|
|
|
|
new-instance v3, Ljava/lang/StringBuilder;
|
|
|
|
|
|
|
|
const-string v4, "RuntimeException while executing runnable "
|
|
|
|
|
|
|
|
invoke-direct {v3, v4}, Ljava/lang/StringBuilder;-><init>(Ljava/lang/String;)V
|
|
|
|
|
|
|
|
invoke-virtual {v3, p0}, Ljava/lang/StringBuilder;->append(Ljava/lang/Object;)Ljava/lang/StringBuilder;
|
|
|
|
|
|
|
|
const-string p0, " with executor "
|
|
|
|
|
|
|
|
invoke-virtual {v3, p0}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;
|
|
|
|
|
|
|
|
invoke-virtual {v3, p1}, Ljava/lang/StringBuilder;->append(Ljava/lang/Object;)Ljava/lang/StringBuilder;
|
|
|
|
|
|
|
|
invoke-virtual {v3}, Ljava/lang/StringBuilder;->toString()Ljava/lang/String;
|
|
|
|
|
|
|
|
move-result-object p0
|
|
|
|
|
|
|
|
invoke-virtual {v1, v2, p0, v0}, Ljava/util/logging/Logger;->log(Ljava/util/logging/Level;Ljava/lang/String;Ljava/lang/Throwable;)V
|
|
|
|
|
|
|
|
return-void
|
|
|
|
.end method
|
|
|
|
|
|
|
|
.method private getDoneValue(Ljava/lang/Object;)Ljava/lang/Object;
|
|
|
|
.locals 1
|
|
|
|
.annotation system Ldalvik/annotation/Signature;
|
|
|
|
value = {
|
|
|
|
"(",
|
|
|
|
"Ljava/lang/Object;",
|
|
|
|
")TV;"
|
|
|
|
}
|
|
|
|
.end annotation
|
|
|
|
|
|
|
|
.annotation system Ldalvik/annotation/Throws;
|
|
|
|
value = {
|
|
|
|
Ljava/util/concurrent/ExecutionException;
|
|
|
|
}
|
|
|
|
.end annotation
|
|
|
|
|
|
|
|
instance-of v0, p1, Landroidx/work/impl/utils/futures/AbstractFuture$Cancellation;
|
|
|
|
|
|
|
|
if-nez v0, :cond_2
|
|
|
|
|
|
|
|
instance-of v0, p1, Landroidx/work/impl/utils/futures/AbstractFuture$Failure;
|
|
|
|
|
|
|
|
if-nez v0, :cond_1
|
|
|
|
|
|
|
|
sget-object v0, Landroidx/work/impl/utils/futures/AbstractFuture;->NULL:Ljava/lang/Object;
|
|
|
|
|
|
|
|
if-ne p1, v0, :cond_0
|
|
|
|
|
|
|
|
const/4 p1, 0x0
|
|
|
|
|
|
|
|
:cond_0
|
|
|
|
return-object p1
|
|
|
|
|
|
|
|
:cond_1
|
|
|
|
new-instance v0, Ljava/util/concurrent/ExecutionException;
|
|
|
|
|
|
|
|
check-cast p1, Landroidx/work/impl/utils/futures/AbstractFuture$Failure;
|
|
|
|
|
|
|
|
iget-object p1, p1, Landroidx/work/impl/utils/futures/AbstractFuture$Failure;->exception:Ljava/lang/Throwable;
|
|
|
|
|
|
|
|
invoke-direct {v0, p1}, Ljava/util/concurrent/ExecutionException;-><init>(Ljava/lang/Throwable;)V
|
|
|
|
|
|
|
|
throw v0
|
|
|
|
|
|
|
|
:cond_2
|
|
|
|
check-cast p1, Landroidx/work/impl/utils/futures/AbstractFuture$Cancellation;
|
|
|
|
|
|
|
|
iget-object p1, p1, Landroidx/work/impl/utils/futures/AbstractFuture$Cancellation;->cause:Ljava/lang/Throwable;
|
|
|
|
|
|
|
|
const-string v0, "Task was cancelled."
|
|
|
|
|
|
|
|
invoke-static {v0, p1}, Landroidx/work/impl/utils/futures/AbstractFuture;->cancellationExceptionWithCause(Ljava/lang/String;Ljava/lang/Throwable;)Ljava/util/concurrent/CancellationException;
|
|
|
|
|
|
|
|
move-result-object p1
|
|
|
|
|
|
|
|
throw p1
|
|
|
|
.end method
|
|
|
|
|
|
|
|
.method static getFutureValue(Lcom/google/a/a/a/a;)Ljava/lang/Object;
|
|
|
|
.locals 4
|
|
|
|
.annotation system Ldalvik/annotation/Signature;
|
|
|
|
value = {
|
|
|
|
"(",
|
|
|
|
"Lcom/google/a/a/a/a<",
|
|
|
|
"*>;)",
|
|
|
|
"Ljava/lang/Object;"
|
|
|
|
}
|
|
|
|
.end annotation
|
|
|
|
|
|
|
|
instance-of v0, p0, Landroidx/work/impl/utils/futures/AbstractFuture;
|
|
|
|
|
|
|
|
const/4 v1, 0x0
|
|
|
|
|
|
|
|
if-eqz v0, :cond_2
|
|
|
|
|
|
|
|
check-cast p0, Landroidx/work/impl/utils/futures/AbstractFuture;
|
|
|
|
|
|
|
|
iget-object p0, p0, Landroidx/work/impl/utils/futures/AbstractFuture;->value:Ljava/lang/Object;
|
|
|
|
|
|
|
|
instance-of v0, p0, Landroidx/work/impl/utils/futures/AbstractFuture$Cancellation;
|
|
|
|
|
|
|
|
if-eqz v0, :cond_1
|
|
|
|
|
|
|
|
move-object v0, p0
|
|
|
|
|
|
|
|
check-cast v0, Landroidx/work/impl/utils/futures/AbstractFuture$Cancellation;
|
|
|
|
|
|
|
|
iget-boolean v2, v0, Landroidx/work/impl/utils/futures/AbstractFuture$Cancellation;->wasInterrupted:Z
|
|
|
|
|
|
|
|
if-eqz v2, :cond_1
|
|
|
|
|
|
|
|
iget-object p0, v0, Landroidx/work/impl/utils/futures/AbstractFuture$Cancellation;->cause:Ljava/lang/Throwable;
|
|
|
|
|
|
|
|
if-eqz p0, :cond_0
|
|
|
|
|
|
|
|
new-instance p0, Landroidx/work/impl/utils/futures/AbstractFuture$Cancellation;
|
|
|
|
|
|
|
|
iget-object v0, v0, Landroidx/work/impl/utils/futures/AbstractFuture$Cancellation;->cause:Ljava/lang/Throwable;
|
|
|
|
|
|
|
|
invoke-direct {p0, v1, v0}, Landroidx/work/impl/utils/futures/AbstractFuture$Cancellation;-><init>(ZLjava/lang/Throwable;)V
|
|
|
|
|
|
|
|
goto :goto_0
|
|
|
|
|
|
|
|
:cond_0
|
|
|
|
sget-object p0, Landroidx/work/impl/utils/futures/AbstractFuture$Cancellation;->CAUSELESS_CANCELLED:Landroidx/work/impl/utils/futures/AbstractFuture$Cancellation;
|
|
|
|
|
|
|
|
:cond_1
|
|
|
|
:goto_0
|
|
|
|
return-object p0
|
|
|
|
|
|
|
|
:cond_2
|
|
|
|
invoke-interface {p0}, Lcom/google/a/a/a/a;->isCancelled()Z
|
|
|
|
|
|
|
|
move-result v0
|
|
|
|
|
|
|
|
sget-boolean v2, Landroidx/work/impl/utils/futures/AbstractFuture;->GENERATE_CANCELLATION_CAUSES:Z
|
|
|
|
|
|
|
|
xor-int/lit8 v2, v2, 0x1
|
|
|
|
|
|
|
|
and-int/2addr v2, v0
|
|
|
|
|
|
|
|
if-eqz v2, :cond_3
|
|
|
|
|
|
|
|
sget-object p0, Landroidx/work/impl/utils/futures/AbstractFuture$Cancellation;->CAUSELESS_CANCELLED:Landroidx/work/impl/utils/futures/AbstractFuture$Cancellation;
|
|
|
|
|
|
|
|
return-object p0
|
|
|
|
|
|
|
|
:cond_3
|
|
|
|
:try_start_0
|
|
|
|
invoke-static {p0}, Landroidx/work/impl/utils/futures/AbstractFuture;->getUninterruptibly(Ljava/util/concurrent/Future;)Ljava/lang/Object;
|
|
|
|
|
|
|
|
move-result-object v2
|
|
|
|
|
|
|
|
if-nez v2, :cond_4
|
|
|
|
|
|
|
|
sget-object p0, Landroidx/work/impl/utils/futures/AbstractFuture;->NULL:Ljava/lang/Object;
|
|
|
|
:try_end_0
|
2019-08-30 20:04:20 +00:00
|
|
|
.catch Ljava/util/concurrent/ExecutionException; {:try_start_0 .. :try_end_0} :catch_1
|
|
|
|
.catch Ljava/util/concurrent/CancellationException; {:try_start_0 .. :try_end_0} :catch_0
|
|
|
|
.catchall {:try_start_0 .. :try_end_0} :catchall_0
|
2019-07-24 11:27:29 +00:00
|
|
|
|
|
|
|
return-object p0
|
|
|
|
|
|
|
|
:cond_4
|
|
|
|
return-object v2
|
|
|
|
|
2019-08-30 20:04:20 +00:00
|
|
|
:catchall_0
|
2019-07-24 11:27:29 +00:00
|
|
|
move-exception p0
|
|
|
|
|
|
|
|
new-instance v0, Landroidx/work/impl/utils/futures/AbstractFuture$Failure;
|
|
|
|
|
|
|
|
invoke-direct {v0, p0}, Landroidx/work/impl/utils/futures/AbstractFuture$Failure;-><init>(Ljava/lang/Throwable;)V
|
|
|
|
|
|
|
|
return-object v0
|
|
|
|
|
2019-08-30 20:04:20 +00:00
|
|
|
:catch_0
|
2019-07-24 11:27:29 +00:00
|
|
|
move-exception v2
|
|
|
|
|
|
|
|
if-nez v0, :cond_5
|
|
|
|
|
|
|
|
new-instance v0, Landroidx/work/impl/utils/futures/AbstractFuture$Failure;
|
|
|
|
|
|
|
|
new-instance v1, Ljava/lang/IllegalArgumentException;
|
|
|
|
|
|
|
|
invoke-static {p0}, Ljava/lang/String;->valueOf(Ljava/lang/Object;)Ljava/lang/String;
|
|
|
|
|
|
|
|
move-result-object p0
|
|
|
|
|
|
|
|
const-string v3, "get() threw CancellationException, despite reporting isCancelled() == false: "
|
|
|
|
|
|
|
|
invoke-virtual {v3, p0}, Ljava/lang/String;->concat(Ljava/lang/String;)Ljava/lang/String;
|
|
|
|
|
|
|
|
move-result-object p0
|
|
|
|
|
|
|
|
invoke-direct {v1, p0, v2}, Ljava/lang/IllegalArgumentException;-><init>(Ljava/lang/String;Ljava/lang/Throwable;)V
|
|
|
|
|
|
|
|
invoke-direct {v0, v1}, Landroidx/work/impl/utils/futures/AbstractFuture$Failure;-><init>(Ljava/lang/Throwable;)V
|
|
|
|
|
|
|
|
return-object v0
|
|
|
|
|
|
|
|
:cond_5
|
|
|
|
new-instance p0, Landroidx/work/impl/utils/futures/AbstractFuture$Cancellation;
|
|
|
|
|
|
|
|
invoke-direct {p0, v1, v2}, Landroidx/work/impl/utils/futures/AbstractFuture$Cancellation;-><init>(ZLjava/lang/Throwable;)V
|
|
|
|
|
|
|
|
return-object p0
|
|
|
|
|
2019-08-30 20:04:20 +00:00
|
|
|
:catch_1
|
2019-07-24 11:27:29 +00:00
|
|
|
move-exception p0
|
|
|
|
|
|
|
|
new-instance v0, Landroidx/work/impl/utils/futures/AbstractFuture$Failure;
|
|
|
|
|
|
|
|
invoke-virtual {p0}, Ljava/util/concurrent/ExecutionException;->getCause()Ljava/lang/Throwable;
|
|
|
|
|
|
|
|
move-result-object p0
|
|
|
|
|
|
|
|
invoke-direct {v0, p0}, Landroidx/work/impl/utils/futures/AbstractFuture$Failure;-><init>(Ljava/lang/Throwable;)V
|
|
|
|
|
|
|
|
return-object v0
|
|
|
|
.end method
|
|
|
|
|
|
|
|
.method private static getUninterruptibly(Ljava/util/concurrent/Future;)Ljava/lang/Object;
|
|
|
|
.locals 1
|
|
|
|
.annotation system Ldalvik/annotation/Signature;
|
|
|
|
value = {
|
|
|
|
"<V:",
|
|
|
|
"Ljava/lang/Object;",
|
|
|
|
">(",
|
|
|
|
"Ljava/util/concurrent/Future<",
|
|
|
|
"TV;>;)TV;"
|
|
|
|
}
|
|
|
|
.end annotation
|
|
|
|
|
|
|
|
.annotation system Ldalvik/annotation/Throws;
|
|
|
|
value = {
|
|
|
|
Ljava/util/concurrent/ExecutionException;
|
|
|
|
}
|
|
|
|
.end annotation
|
|
|
|
|
|
|
|
const/4 v0, 0x0
|
|
|
|
|
|
|
|
:goto_0
|
|
|
|
:try_start_0
|
|
|
|
invoke-interface {p0}, Ljava/util/concurrent/Future;->get()Ljava/lang/Object;
|
|
|
|
|
|
|
|
move-result-object p0
|
|
|
|
:try_end_0
|
|
|
|
.catch Ljava/lang/InterruptedException; {:try_start_0 .. :try_end_0} :catch_0
|
|
|
|
.catchall {:try_start_0 .. :try_end_0} :catchall_0
|
|
|
|
|
|
|
|
if-eqz v0, :cond_0
|
|
|
|
|
|
|
|
invoke-static {}, Ljava/lang/Thread;->currentThread()Ljava/lang/Thread;
|
|
|
|
|
|
|
|
move-result-object v0
|
|
|
|
|
|
|
|
invoke-virtual {v0}, Ljava/lang/Thread;->interrupt()V
|
|
|
|
|
|
|
|
:cond_0
|
|
|
|
return-object p0
|
|
|
|
|
|
|
|
:catchall_0
|
|
|
|
move-exception p0
|
|
|
|
|
|
|
|
if-eqz v0, :cond_1
|
|
|
|
|
|
|
|
invoke-static {}, Ljava/lang/Thread;->currentThread()Ljava/lang/Thread;
|
|
|
|
|
|
|
|
move-result-object v0
|
|
|
|
|
|
|
|
invoke-virtual {v0}, Ljava/lang/Thread;->interrupt()V
|
|
|
|
|
|
|
|
:cond_1
|
|
|
|
throw p0
|
|
|
|
|
|
|
|
:catch_0
|
|
|
|
const/4 v0, 0x1
|
|
|
|
|
|
|
|
goto :goto_0
|
|
|
|
.end method
|
|
|
|
|
|
|
|
.method private releaseWaiters()V
|
|
|
|
.locals 3
|
|
|
|
|
|
|
|
:cond_0
|
|
|
|
iget-object v0, p0, Landroidx/work/impl/utils/futures/AbstractFuture;->waiters:Landroidx/work/impl/utils/futures/AbstractFuture$Waiter;
|
|
|
|
|
|
|
|
sget-object v1, Landroidx/work/impl/utils/futures/AbstractFuture;->ATOMIC_HELPER:Landroidx/work/impl/utils/futures/AbstractFuture$AtomicHelper;
|
|
|
|
|
|
|
|
sget-object v2, Landroidx/work/impl/utils/futures/AbstractFuture$Waiter;->TOMBSTONE:Landroidx/work/impl/utils/futures/AbstractFuture$Waiter;
|
|
|
|
|
|
|
|
invoke-virtual {v1, p0, v0, v2}, Landroidx/work/impl/utils/futures/AbstractFuture$AtomicHelper;->casWaiters(Landroidx/work/impl/utils/futures/AbstractFuture;Landroidx/work/impl/utils/futures/AbstractFuture$Waiter;Landroidx/work/impl/utils/futures/AbstractFuture$Waiter;)Z
|
|
|
|
|
|
|
|
move-result v1
|
|
|
|
|
|
|
|
if-eqz v1, :cond_0
|
|
|
|
|
|
|
|
:goto_0
|
|
|
|
if-eqz v0, :cond_1
|
|
|
|
|
|
|
|
invoke-virtual {v0}, Landroidx/work/impl/utils/futures/AbstractFuture$Waiter;->unpark()V
|
|
|
|
|
|
|
|
iget-object v0, v0, Landroidx/work/impl/utils/futures/AbstractFuture$Waiter;->next:Landroidx/work/impl/utils/futures/AbstractFuture$Waiter;
|
|
|
|
|
|
|
|
goto :goto_0
|
|
|
|
|
|
|
|
:cond_1
|
|
|
|
return-void
|
|
|
|
.end method
|
|
|
|
|
|
|
|
.method private removeWaiter(Landroidx/work/impl/utils/futures/AbstractFuture$Waiter;)V
|
|
|
|
.locals 4
|
|
|
|
|
|
|
|
const/4 v0, 0x0
|
|
|
|
|
|
|
|
iput-object v0, p1, Landroidx/work/impl/utils/futures/AbstractFuture$Waiter;->thread:Ljava/lang/Thread;
|
|
|
|
|
|
|
|
:cond_0
|
|
|
|
:goto_0
|
|
|
|
iget-object p1, p0, Landroidx/work/impl/utils/futures/AbstractFuture;->waiters:Landroidx/work/impl/utils/futures/AbstractFuture$Waiter;
|
|
|
|
|
|
|
|
sget-object v1, Landroidx/work/impl/utils/futures/AbstractFuture$Waiter;->TOMBSTONE:Landroidx/work/impl/utils/futures/AbstractFuture$Waiter;
|
|
|
|
|
|
|
|
if-ne p1, v1, :cond_1
|
|
|
|
|
|
|
|
return-void
|
|
|
|
|
|
|
|
:cond_1
|
|
|
|
move-object v1, v0
|
|
|
|
|
|
|
|
:goto_1
|
|
|
|
if-eqz p1, :cond_5
|
|
|
|
|
|
|
|
iget-object v2, p1, Landroidx/work/impl/utils/futures/AbstractFuture$Waiter;->next:Landroidx/work/impl/utils/futures/AbstractFuture$Waiter;
|
|
|
|
|
|
|
|
iget-object v3, p1, Landroidx/work/impl/utils/futures/AbstractFuture$Waiter;->thread:Ljava/lang/Thread;
|
|
|
|
|
|
|
|
if-eqz v3, :cond_2
|
|
|
|
|
|
|
|
move-object v1, p1
|
|
|
|
|
|
|
|
goto :goto_2
|
|
|
|
|
|
|
|
:cond_2
|
|
|
|
if-eqz v1, :cond_3
|
|
|
|
|
|
|
|
iput-object v2, v1, Landroidx/work/impl/utils/futures/AbstractFuture$Waiter;->next:Landroidx/work/impl/utils/futures/AbstractFuture$Waiter;
|
|
|
|
|
|
|
|
iget-object p1, v1, Landroidx/work/impl/utils/futures/AbstractFuture$Waiter;->thread:Ljava/lang/Thread;
|
|
|
|
|
|
|
|
if-nez p1, :cond_4
|
|
|
|
|
|
|
|
goto :goto_0
|
|
|
|
|
|
|
|
:cond_3
|
|
|
|
sget-object v3, Landroidx/work/impl/utils/futures/AbstractFuture;->ATOMIC_HELPER:Landroidx/work/impl/utils/futures/AbstractFuture$AtomicHelper;
|
|
|
|
|
|
|
|
invoke-virtual {v3, p0, p1, v2}, Landroidx/work/impl/utils/futures/AbstractFuture$AtomicHelper;->casWaiters(Landroidx/work/impl/utils/futures/AbstractFuture;Landroidx/work/impl/utils/futures/AbstractFuture$Waiter;Landroidx/work/impl/utils/futures/AbstractFuture$Waiter;)Z
|
|
|
|
|
|
|
|
move-result p1
|
|
|
|
|
|
|
|
if-eqz p1, :cond_0
|
|
|
|
|
|
|
|
:cond_4
|
|
|
|
:goto_2
|
|
|
|
move-object p1, v2
|
|
|
|
|
|
|
|
goto :goto_1
|
|
|
|
|
|
|
|
:cond_5
|
|
|
|
return-void
|
|
|
|
.end method
|
|
|
|
|
|
|
|
.method private userObjectToString(Ljava/lang/Object;)Ljava/lang/String;
|
|
|
|
.locals 0
|
|
|
|
|
|
|
|
if-ne p1, p0, :cond_0
|
|
|
|
|
|
|
|
const-string p1, "this future"
|
|
|
|
|
|
|
|
return-object p1
|
|
|
|
|
|
|
|
:cond_0
|
|
|
|
invoke-static {p1}, Ljava/lang/String;->valueOf(Ljava/lang/Object;)Ljava/lang/String;
|
|
|
|
|
|
|
|
move-result-object p1
|
|
|
|
|
|
|
|
return-object p1
|
|
|
|
.end method
|
|
|
|
|
|
|
|
|
|
|
|
# virtual methods
|
|
|
|
.method public final addListener(Ljava/lang/Runnable;Ljava/util/concurrent/Executor;)V
|
|
|
|
.locals 3
|
|
|
|
|
|
|
|
invoke-static {p1}, Landroidx/work/impl/utils/futures/AbstractFuture;->checkNotNull(Ljava/lang/Object;)Ljava/lang/Object;
|
|
|
|
|
|
|
|
invoke-static {p2}, Landroidx/work/impl/utils/futures/AbstractFuture;->checkNotNull(Ljava/lang/Object;)Ljava/lang/Object;
|
|
|
|
|
|
|
|
iget-object v0, p0, Landroidx/work/impl/utils/futures/AbstractFuture;->listeners:Landroidx/work/impl/utils/futures/AbstractFuture$Listener;
|
|
|
|
|
|
|
|
sget-object v1, Landroidx/work/impl/utils/futures/AbstractFuture$Listener;->TOMBSTONE:Landroidx/work/impl/utils/futures/AbstractFuture$Listener;
|
|
|
|
|
|
|
|
if-eq v0, v1, :cond_2
|
|
|
|
|
|
|
|
new-instance v1, Landroidx/work/impl/utils/futures/AbstractFuture$Listener;
|
|
|
|
|
|
|
|
invoke-direct {v1, p1, p2}, Landroidx/work/impl/utils/futures/AbstractFuture$Listener;-><init>(Ljava/lang/Runnable;Ljava/util/concurrent/Executor;)V
|
|
|
|
|
|
|
|
:cond_0
|
|
|
|
iput-object v0, v1, Landroidx/work/impl/utils/futures/AbstractFuture$Listener;->next:Landroidx/work/impl/utils/futures/AbstractFuture$Listener;
|
|
|
|
|
|
|
|
sget-object v2, Landroidx/work/impl/utils/futures/AbstractFuture;->ATOMIC_HELPER:Landroidx/work/impl/utils/futures/AbstractFuture$AtomicHelper;
|
|
|
|
|
|
|
|
invoke-virtual {v2, p0, v0, v1}, Landroidx/work/impl/utils/futures/AbstractFuture$AtomicHelper;->casListeners(Landroidx/work/impl/utils/futures/AbstractFuture;Landroidx/work/impl/utils/futures/AbstractFuture$Listener;Landroidx/work/impl/utils/futures/AbstractFuture$Listener;)Z
|
|
|
|
|
|
|
|
move-result v0
|
|
|
|
|
|
|
|
if-eqz v0, :cond_1
|
|
|
|
|
|
|
|
return-void
|
|
|
|
|
|
|
|
:cond_1
|
|
|
|
iget-object v0, p0, Landroidx/work/impl/utils/futures/AbstractFuture;->listeners:Landroidx/work/impl/utils/futures/AbstractFuture$Listener;
|
|
|
|
|
|
|
|
sget-object v2, Landroidx/work/impl/utils/futures/AbstractFuture$Listener;->TOMBSTONE:Landroidx/work/impl/utils/futures/AbstractFuture$Listener;
|
|
|
|
|
|
|
|
if-ne v0, v2, :cond_0
|
|
|
|
|
|
|
|
:cond_2
|
|
|
|
invoke-static {p1, p2}, Landroidx/work/impl/utils/futures/AbstractFuture;->executeListener(Ljava/lang/Runnable;Ljava/util/concurrent/Executor;)V
|
|
|
|
|
|
|
|
return-void
|
|
|
|
.end method
|
|
|
|
|
|
|
|
.method protected afterDone()V
|
|
|
|
.locals 0
|
|
|
|
|
|
|
|
return-void
|
|
|
|
.end method
|
|
|
|
|
|
|
|
.method public final cancel(Z)Z
|
|
|
|
.locals 7
|
|
|
|
|
|
|
|
iget-object v0, p0, Landroidx/work/impl/utils/futures/AbstractFuture;->value:Ljava/lang/Object;
|
|
|
|
|
|
|
|
const/4 v1, 0x1
|
|
|
|
|
|
|
|
const/4 v2, 0x0
|
|
|
|
|
|
|
|
if-nez v0, :cond_0
|
|
|
|
|
|
|
|
const/4 v3, 0x1
|
|
|
|
|
|
|
|
goto :goto_0
|
|
|
|
|
|
|
|
:cond_0
|
|
|
|
const/4 v3, 0x0
|
|
|
|
|
|
|
|
:goto_0
|
|
|
|
instance-of v4, v0, Landroidx/work/impl/utils/futures/AbstractFuture$SetFuture;
|
|
|
|
|
|
|
|
or-int/2addr v3, v4
|
|
|
|
|
|
|
|
if-eqz v3, :cond_8
|
|
|
|
|
|
|
|
sget-boolean v3, Landroidx/work/impl/utils/futures/AbstractFuture;->GENERATE_CANCELLATION_CAUSES:Z
|
|
|
|
|
|
|
|
if-eqz v3, :cond_1
|
|
|
|
|
|
|
|
new-instance v3, Landroidx/work/impl/utils/futures/AbstractFuture$Cancellation;
|
|
|
|
|
|
|
|
new-instance v4, Ljava/util/concurrent/CancellationException;
|
|
|
|
|
|
|
|
const-string v5, "Future.cancel() was called."
|
|
|
|
|
|
|
|
invoke-direct {v4, v5}, Ljava/util/concurrent/CancellationException;-><init>(Ljava/lang/String;)V
|
|
|
|
|
|
|
|
invoke-direct {v3, p1, v4}, Landroidx/work/impl/utils/futures/AbstractFuture$Cancellation;-><init>(ZLjava/lang/Throwable;)V
|
|
|
|
|
|
|
|
goto :goto_1
|
|
|
|
|
|
|
|
:cond_1
|
|
|
|
if-eqz p1, :cond_2
|
|
|
|
|
|
|
|
sget-object v3, Landroidx/work/impl/utils/futures/AbstractFuture$Cancellation;->CAUSELESS_INTERRUPTED:Landroidx/work/impl/utils/futures/AbstractFuture$Cancellation;
|
|
|
|
|
|
|
|
goto :goto_1
|
|
|
|
|
|
|
|
:cond_2
|
|
|
|
sget-object v3, Landroidx/work/impl/utils/futures/AbstractFuture$Cancellation;->CAUSELESS_CANCELLED:Landroidx/work/impl/utils/futures/AbstractFuture$Cancellation;
|
|
|
|
|
|
|
|
:goto_1
|
|
|
|
const/4 v5, 0x0
|
|
|
|
|
|
|
|
move-object v4, v0
|
|
|
|
|
|
|
|
move-object v0, p0
|
|
|
|
|
|
|
|
:cond_3
|
|
|
|
:goto_2
|
|
|
|
sget-object v6, Landroidx/work/impl/utils/futures/AbstractFuture;->ATOMIC_HELPER:Landroidx/work/impl/utils/futures/AbstractFuture$AtomicHelper;
|
|
|
|
|
|
|
|
invoke-virtual {v6, v0, v4, v3}, Landroidx/work/impl/utils/futures/AbstractFuture$AtomicHelper;->casValue(Landroidx/work/impl/utils/futures/AbstractFuture;Ljava/lang/Object;Ljava/lang/Object;)Z
|
|
|
|
|
|
|
|
move-result v6
|
|
|
|
|
|
|
|
if-eqz v6, :cond_7
|
|
|
|
|
|
|
|
if-eqz p1, :cond_4
|
|
|
|
|
|
|
|
invoke-virtual {v0}, Landroidx/work/impl/utils/futures/AbstractFuture;->interruptTask()V
|
|
|
|
|
|
|
|
:cond_4
|
|
|
|
invoke-static {v0}, Landroidx/work/impl/utils/futures/AbstractFuture;->complete(Landroidx/work/impl/utils/futures/AbstractFuture;)V
|
|
|
|
|
|
|
|
instance-of v0, v4, Landroidx/work/impl/utils/futures/AbstractFuture$SetFuture;
|
|
|
|
|
|
|
|
if-eqz v0, :cond_9
|
|
|
|
|
|
|
|
check-cast v4, Landroidx/work/impl/utils/futures/AbstractFuture$SetFuture;
|
|
|
|
|
|
|
|
iget-object v0, v4, Landroidx/work/impl/utils/futures/AbstractFuture$SetFuture;->future:Lcom/google/a/a/a/a;
|
|
|
|
|
|
|
|
instance-of v4, v0, Landroidx/work/impl/utils/futures/AbstractFuture;
|
|
|
|
|
|
|
|
if-eqz v4, :cond_6
|
|
|
|
|
|
|
|
check-cast v0, Landroidx/work/impl/utils/futures/AbstractFuture;
|
|
|
|
|
|
|
|
iget-object v4, v0, Landroidx/work/impl/utils/futures/AbstractFuture;->value:Ljava/lang/Object;
|
|
|
|
|
|
|
|
if-nez v4, :cond_5
|
|
|
|
|
|
|
|
const/4 v5, 0x1
|
|
|
|
|
|
|
|
goto :goto_3
|
|
|
|
|
|
|
|
:cond_5
|
|
|
|
const/4 v5, 0x0
|
|
|
|
|
|
|
|
:goto_3
|
|
|
|
instance-of v6, v4, Landroidx/work/impl/utils/futures/AbstractFuture$SetFuture;
|
|
|
|
|
|
|
|
or-int/2addr v5, v6
|
|
|
|
|
|
|
|
if-eqz v5, :cond_9
|
|
|
|
|
|
|
|
const/4 v5, 0x1
|
|
|
|
|
|
|
|
goto :goto_2
|
|
|
|
|
|
|
|
:cond_6
|
|
|
|
invoke-interface {v0, p1}, Lcom/google/a/a/a/a;->cancel(Z)Z
|
|
|
|
|
|
|
|
goto :goto_4
|
|
|
|
|
|
|
|
:cond_7
|
|
|
|
iget-object v4, v0, Landroidx/work/impl/utils/futures/AbstractFuture;->value:Ljava/lang/Object;
|
|
|
|
|
|
|
|
instance-of v6, v4, Landroidx/work/impl/utils/futures/AbstractFuture$SetFuture;
|
|
|
|
|
|
|
|
if-nez v6, :cond_3
|
|
|
|
|
|
|
|
move v1, v5
|
|
|
|
|
|
|
|
goto :goto_4
|
|
|
|
|
|
|
|
:cond_8
|
|
|
|
const/4 v1, 0x0
|
|
|
|
|
|
|
|
:cond_9
|
|
|
|
:goto_4
|
|
|
|
return v1
|
|
|
|
.end method
|
|
|
|
|
|
|
|
.method public final get()Ljava/lang/Object;
|
|
|
|
.locals 6
|
|
|
|
.annotation system Ldalvik/annotation/Signature;
|
|
|
|
value = {
|
|
|
|
"()TV;"
|
|
|
|
}
|
|
|
|
.end annotation
|
|
|
|
|
|
|
|
.annotation system Ldalvik/annotation/Throws;
|
|
|
|
value = {
|
|
|
|
Ljava/lang/InterruptedException;,
|
|
|
|
Ljava/util/concurrent/ExecutionException;
|
|
|
|
}
|
|
|
|
.end annotation
|
|
|
|
|
|
|
|
invoke-static {}, Ljava/lang/Thread;->interrupted()Z
|
|
|
|
|
|
|
|
move-result v0
|
|
|
|
|
2019-08-30 20:04:20 +00:00
|
|
|
if-nez v0, :cond_8
|
2019-07-24 11:27:29 +00:00
|
|
|
|
|
|
|
iget-object v0, p0, Landroidx/work/impl/utils/futures/AbstractFuture;->value:Ljava/lang/Object;
|
|
|
|
|
2019-08-30 20:04:20 +00:00
|
|
|
const/4 v1, 0x0
|
2019-07-24 11:27:29 +00:00
|
|
|
|
2019-08-30 20:04:20 +00:00
|
|
|
const/4 v2, 0x1
|
2019-07-24 11:27:29 +00:00
|
|
|
|
|
|
|
if-eqz v0, :cond_0
|
|
|
|
|
|
|
|
const/4 v3, 0x1
|
|
|
|
|
|
|
|
goto :goto_0
|
|
|
|
|
|
|
|
:cond_0
|
|
|
|
const/4 v3, 0x0
|
|
|
|
|
|
|
|
:goto_0
|
|
|
|
instance-of v4, v0, Landroidx/work/impl/utils/futures/AbstractFuture$SetFuture;
|
|
|
|
|
2019-08-30 20:04:20 +00:00
|
|
|
xor-int/2addr v4, v2
|
2019-07-24 11:27:29 +00:00
|
|
|
|
|
|
|
and-int/2addr v3, v4
|
|
|
|
|
2019-08-30 20:04:20 +00:00
|
|
|
if-eqz v3, :cond_1
|
2019-07-24 11:27:29 +00:00
|
|
|
|
|
|
|
invoke-direct {p0, v0}, Landroidx/work/impl/utils/futures/AbstractFuture;->getDoneValue(Ljava/lang/Object;)Ljava/lang/Object;
|
|
|
|
|
|
|
|
move-result-object v0
|
|
|
|
|
|
|
|
return-object v0
|
|
|
|
|
2019-08-30 20:04:20 +00:00
|
|
|
:cond_1
|
2019-07-24 11:27:29 +00:00
|
|
|
iget-object v0, p0, Landroidx/work/impl/utils/futures/AbstractFuture;->waiters:Landroidx/work/impl/utils/futures/AbstractFuture$Waiter;
|
|
|
|
|
|
|
|
sget-object v3, Landroidx/work/impl/utils/futures/AbstractFuture$Waiter;->TOMBSTONE:Landroidx/work/impl/utils/futures/AbstractFuture$Waiter;
|
|
|
|
|
2019-08-30 20:04:20 +00:00
|
|
|
if-eq v0, v3, :cond_7
|
2019-07-24 11:27:29 +00:00
|
|
|
|
|
|
|
new-instance v3, Landroidx/work/impl/utils/futures/AbstractFuture$Waiter;
|
|
|
|
|
|
|
|
invoke-direct {v3}, Landroidx/work/impl/utils/futures/AbstractFuture$Waiter;-><init>()V
|
|
|
|
|
2019-08-30 20:04:20 +00:00
|
|
|
:cond_2
|
2019-07-24 11:27:29 +00:00
|
|
|
invoke-virtual {v3, v0}, Landroidx/work/impl/utils/futures/AbstractFuture$Waiter;->setNext(Landroidx/work/impl/utils/futures/AbstractFuture$Waiter;)V
|
|
|
|
|
|
|
|
sget-object v4, Landroidx/work/impl/utils/futures/AbstractFuture;->ATOMIC_HELPER:Landroidx/work/impl/utils/futures/AbstractFuture$AtomicHelper;
|
|
|
|
|
|
|
|
invoke-virtual {v4, p0, v0, v3}, Landroidx/work/impl/utils/futures/AbstractFuture$AtomicHelper;->casWaiters(Landroidx/work/impl/utils/futures/AbstractFuture;Landroidx/work/impl/utils/futures/AbstractFuture$Waiter;Landroidx/work/impl/utils/futures/AbstractFuture$Waiter;)Z
|
|
|
|
|
|
|
|
move-result v0
|
|
|
|
|
2019-08-30 20:04:20 +00:00
|
|
|
if-eqz v0, :cond_6
|
2019-07-24 11:27:29 +00:00
|
|
|
|
2019-08-30 20:04:20 +00:00
|
|
|
:cond_3
|
2019-07-24 11:27:29 +00:00
|
|
|
invoke-static {p0}, Ljava/util/concurrent/locks/LockSupport;->park(Ljava/lang/Object;)V
|
|
|
|
|
|
|
|
invoke-static {}, Ljava/lang/Thread;->interrupted()Z
|
|
|
|
|
|
|
|
move-result v0
|
|
|
|
|
2019-08-30 20:04:20 +00:00
|
|
|
if-nez v0, :cond_5
|
2019-07-24 11:27:29 +00:00
|
|
|
|
|
|
|
iget-object v0, p0, Landroidx/work/impl/utils/futures/AbstractFuture;->value:Ljava/lang/Object;
|
|
|
|
|
2019-08-30 20:04:20 +00:00
|
|
|
if-eqz v0, :cond_4
|
2019-07-24 11:27:29 +00:00
|
|
|
|
|
|
|
const/4 v4, 0x1
|
|
|
|
|
2019-08-30 20:04:20 +00:00
|
|
|
goto :goto_1
|
2019-07-24 11:27:29 +00:00
|
|
|
|
2019-08-30 20:04:20 +00:00
|
|
|
:cond_4
|
2019-07-24 11:27:29 +00:00
|
|
|
const/4 v4, 0x0
|
|
|
|
|
2019-08-30 20:04:20 +00:00
|
|
|
:goto_1
|
2019-07-24 11:27:29 +00:00
|
|
|
instance-of v5, v0, Landroidx/work/impl/utils/futures/AbstractFuture$SetFuture;
|
|
|
|
|
2019-08-30 20:04:20 +00:00
|
|
|
xor-int/2addr v5, v2
|
2019-07-24 11:27:29 +00:00
|
|
|
|
|
|
|
and-int/2addr v4, v5
|
|
|
|
|
2019-08-30 20:04:20 +00:00
|
|
|
if-eqz v4, :cond_3
|
2019-07-24 11:27:29 +00:00
|
|
|
|
|
|
|
invoke-direct {p0, v0}, Landroidx/work/impl/utils/futures/AbstractFuture;->getDoneValue(Ljava/lang/Object;)Ljava/lang/Object;
|
|
|
|
|
|
|
|
move-result-object v0
|
|
|
|
|
|
|
|
return-object v0
|
|
|
|
|
2019-08-30 20:04:20 +00:00
|
|
|
:cond_5
|
2019-07-24 11:27:29 +00:00
|
|
|
invoke-direct {p0, v3}, Landroidx/work/impl/utils/futures/AbstractFuture;->removeWaiter(Landroidx/work/impl/utils/futures/AbstractFuture$Waiter;)V
|
|
|
|
|
|
|
|
new-instance v0, Ljava/lang/InterruptedException;
|
|
|
|
|
|
|
|
invoke-direct {v0}, Ljava/lang/InterruptedException;-><init>()V
|
|
|
|
|
|
|
|
throw v0
|
|
|
|
|
2019-08-30 20:04:20 +00:00
|
|
|
:cond_6
|
2019-07-24 11:27:29 +00:00
|
|
|
iget-object v0, p0, Landroidx/work/impl/utils/futures/AbstractFuture;->waiters:Landroidx/work/impl/utils/futures/AbstractFuture$Waiter;
|
|
|
|
|
|
|
|
sget-object v4, Landroidx/work/impl/utils/futures/AbstractFuture$Waiter;->TOMBSTONE:Landroidx/work/impl/utils/futures/AbstractFuture$Waiter;
|
|
|
|
|
2019-08-30 20:04:20 +00:00
|
|
|
if-ne v0, v4, :cond_2
|
2019-07-24 11:27:29 +00:00
|
|
|
|
2019-08-30 20:04:20 +00:00
|
|
|
:cond_7
|
2019-07-24 11:27:29 +00:00
|
|
|
iget-object v0, p0, Landroidx/work/impl/utils/futures/AbstractFuture;->value:Ljava/lang/Object;
|
|
|
|
|
|
|
|
invoke-direct {p0, v0}, Landroidx/work/impl/utils/futures/AbstractFuture;->getDoneValue(Ljava/lang/Object;)Ljava/lang/Object;
|
|
|
|
|
|
|
|
move-result-object v0
|
|
|
|
|
|
|
|
return-object v0
|
|
|
|
|
2019-08-30 20:04:20 +00:00
|
|
|
:cond_8
|
2019-07-24 11:27:29 +00:00
|
|
|
new-instance v0, Ljava/lang/InterruptedException;
|
|
|
|
|
|
|
|
invoke-direct {v0}, Ljava/lang/InterruptedException;-><init>()V
|
|
|
|
|
|
|
|
throw v0
|
|
|
|
.end method
|
|
|
|
|
|
|
|
.method public final get(JLjava/util/concurrent/TimeUnit;)Ljava/lang/Object;
|
|
|
|
.locals 19
|
|
|
|
.annotation system Ldalvik/annotation/Signature;
|
|
|
|
value = {
|
|
|
|
"(J",
|
|
|
|
"Ljava/util/concurrent/TimeUnit;",
|
|
|
|
")TV;"
|
|
|
|
}
|
|
|
|
.end annotation
|
|
|
|
|
|
|
|
.annotation system Ldalvik/annotation/Throws;
|
|
|
|
value = {
|
|
|
|
Ljava/lang/InterruptedException;,
|
|
|
|
Ljava/util/concurrent/TimeoutException;,
|
|
|
|
Ljava/util/concurrent/ExecutionException;
|
|
|
|
}
|
|
|
|
.end annotation
|
|
|
|
|
|
|
|
move-object/from16 v0, p0
|
|
|
|
|
|
|
|
move-wide/from16 v1, p1
|
|
|
|
|
|
|
|
move-object/from16 v3, p3
|
|
|
|
|
|
|
|
invoke-virtual {v3, v1, v2}, Ljava/util/concurrent/TimeUnit;->toNanos(J)J
|
|
|
|
|
|
|
|
move-result-wide v4
|
|
|
|
|
|
|
|
invoke-static {}, Ljava/lang/Thread;->interrupted()Z
|
|
|
|
|
|
|
|
move-result v6
|
|
|
|
|
2019-08-30 20:04:20 +00:00
|
|
|
if-nez v6, :cond_16
|
2019-07-24 11:27:29 +00:00
|
|
|
|
|
|
|
iget-object v6, v0, Landroidx/work/impl/utils/futures/AbstractFuture;->value:Ljava/lang/Object;
|
|
|
|
|
2019-08-30 20:04:20 +00:00
|
|
|
const/4 v8, 0x1
|
2019-07-24 11:27:29 +00:00
|
|
|
|
|
|
|
if-eqz v6, :cond_0
|
|
|
|
|
|
|
|
const/4 v9, 0x1
|
|
|
|
|
|
|
|
goto :goto_0
|
|
|
|
|
|
|
|
:cond_0
|
|
|
|
const/4 v9, 0x0
|
|
|
|
|
|
|
|
:goto_0
|
|
|
|
instance-of v10, v6, Landroidx/work/impl/utils/futures/AbstractFuture$SetFuture;
|
|
|
|
|
2019-08-30 20:04:20 +00:00
|
|
|
xor-int/2addr v10, v8
|
2019-07-24 11:27:29 +00:00
|
|
|
|
|
|
|
and-int/2addr v9, v10
|
|
|
|
|
2019-08-30 20:04:20 +00:00
|
|
|
if-eqz v9, :cond_1
|
2019-07-24 11:27:29 +00:00
|
|
|
|
|
|
|
invoke-direct {v0, v6}, Landroidx/work/impl/utils/futures/AbstractFuture;->getDoneValue(Ljava/lang/Object;)Ljava/lang/Object;
|
|
|
|
|
|
|
|
move-result-object v1
|
|
|
|
|
|
|
|
return-object v1
|
|
|
|
|
2019-08-30 20:04:20 +00:00
|
|
|
:cond_1
|
2019-07-24 11:27:29 +00:00
|
|
|
const-wide/16 v9, 0x0
|
|
|
|
|
|
|
|
cmp-long v6, v4, v9
|
|
|
|
|
2019-08-30 20:04:20 +00:00
|
|
|
if-lez v6, :cond_2
|
2019-07-24 11:27:29 +00:00
|
|
|
|
|
|
|
invoke-static {}, Ljava/lang/System;->nanoTime()J
|
|
|
|
|
|
|
|
move-result-wide v11
|
|
|
|
|
|
|
|
add-long/2addr v11, v4
|
|
|
|
|
2019-08-30 20:04:20 +00:00
|
|
|
goto :goto_1
|
2019-07-24 11:27:29 +00:00
|
|
|
|
2019-08-30 20:04:20 +00:00
|
|
|
:cond_2
|
2019-07-24 11:27:29 +00:00
|
|
|
move-wide v11, v9
|
|
|
|
|
2019-08-30 20:04:20 +00:00
|
|
|
:goto_1
|
2019-07-24 11:27:29 +00:00
|
|
|
const-wide/16 v13, 0x3e8
|
|
|
|
|
|
|
|
cmp-long v6, v4, v13
|
|
|
|
|
2019-08-30 20:04:20 +00:00
|
|
|
if-ltz v6, :cond_a
|
2019-07-24 11:27:29 +00:00
|
|
|
|
|
|
|
iget-object v6, v0, Landroidx/work/impl/utils/futures/AbstractFuture;->waiters:Landroidx/work/impl/utils/futures/AbstractFuture$Waiter;
|
|
|
|
|
|
|
|
sget-object v15, Landroidx/work/impl/utils/futures/AbstractFuture$Waiter;->TOMBSTONE:Landroidx/work/impl/utils/futures/AbstractFuture$Waiter;
|
|
|
|
|
2019-08-30 20:04:20 +00:00
|
|
|
if-eq v6, v15, :cond_9
|
2019-07-24 11:27:29 +00:00
|
|
|
|
|
|
|
new-instance v15, Landroidx/work/impl/utils/futures/AbstractFuture$Waiter;
|
|
|
|
|
|
|
|
invoke-direct {v15}, Landroidx/work/impl/utils/futures/AbstractFuture$Waiter;-><init>()V
|
|
|
|
|
2019-08-30 20:04:20 +00:00
|
|
|
:cond_3
|
2019-07-24 11:27:29 +00:00
|
|
|
invoke-virtual {v15, v6}, Landroidx/work/impl/utils/futures/AbstractFuture$Waiter;->setNext(Landroidx/work/impl/utils/futures/AbstractFuture$Waiter;)V
|
|
|
|
|
|
|
|
sget-object v7, Landroidx/work/impl/utils/futures/AbstractFuture;->ATOMIC_HELPER:Landroidx/work/impl/utils/futures/AbstractFuture$AtomicHelper;
|
|
|
|
|
|
|
|
invoke-virtual {v7, v0, v6, v15}, Landroidx/work/impl/utils/futures/AbstractFuture$AtomicHelper;->casWaiters(Landroidx/work/impl/utils/futures/AbstractFuture;Landroidx/work/impl/utils/futures/AbstractFuture$Waiter;Landroidx/work/impl/utils/futures/AbstractFuture$Waiter;)Z
|
|
|
|
|
|
|
|
move-result v6
|
|
|
|
|
2019-08-30 20:04:20 +00:00
|
|
|
if-eqz v6, :cond_8
|
2019-07-24 11:27:29 +00:00
|
|
|
|
2019-08-30 20:04:20 +00:00
|
|
|
:cond_4
|
2019-07-24 11:27:29 +00:00
|
|
|
invoke-static {v0, v4, v5}, Ljava/util/concurrent/locks/LockSupport;->parkNanos(Ljava/lang/Object;J)V
|
|
|
|
|
|
|
|
invoke-static {}, Ljava/lang/Thread;->interrupted()Z
|
|
|
|
|
|
|
|
move-result v4
|
|
|
|
|
2019-08-30 20:04:20 +00:00
|
|
|
if-nez v4, :cond_7
|
2019-07-24 11:27:29 +00:00
|
|
|
|
|
|
|
iget-object v4, v0, Landroidx/work/impl/utils/futures/AbstractFuture;->value:Ljava/lang/Object;
|
|
|
|
|
2019-08-30 20:04:20 +00:00
|
|
|
if-eqz v4, :cond_5
|
2019-07-24 11:27:29 +00:00
|
|
|
|
|
|
|
const/4 v5, 0x1
|
|
|
|
|
2019-08-30 20:04:20 +00:00
|
|
|
goto :goto_2
|
2019-07-24 11:27:29 +00:00
|
|
|
|
2019-08-30 20:04:20 +00:00
|
|
|
:cond_5
|
2019-07-24 11:27:29 +00:00
|
|
|
const/4 v5, 0x0
|
|
|
|
|
2019-08-30 20:04:20 +00:00
|
|
|
:goto_2
|
2019-07-24 11:27:29 +00:00
|
|
|
instance-of v6, v4, Landroidx/work/impl/utils/futures/AbstractFuture$SetFuture;
|
|
|
|
|
2019-08-30 20:04:20 +00:00
|
|
|
xor-int/2addr v6, v8
|
2019-07-24 11:27:29 +00:00
|
|
|
|
|
|
|
and-int/2addr v5, v6
|
|
|
|
|
2019-08-30 20:04:20 +00:00
|
|
|
if-eqz v5, :cond_6
|
2019-07-24 11:27:29 +00:00
|
|
|
|
|
|
|
invoke-direct {v0, v4}, Landroidx/work/impl/utils/futures/AbstractFuture;->getDoneValue(Ljava/lang/Object;)Ljava/lang/Object;
|
|
|
|
|
|
|
|
move-result-object v1
|
|
|
|
|
|
|
|
return-object v1
|
|
|
|
|
2019-08-30 20:04:20 +00:00
|
|
|
:cond_6
|
2019-07-24 11:27:29 +00:00
|
|
|
invoke-static {}, Ljava/lang/System;->nanoTime()J
|
|
|
|
|
|
|
|
move-result-wide v4
|
|
|
|
|
|
|
|
sub-long v4, v11, v4
|
|
|
|
|
|
|
|
cmp-long v6, v4, v13
|
|
|
|
|
2019-08-30 20:04:20 +00:00
|
|
|
if-gez v6, :cond_4
|
2019-07-24 11:27:29 +00:00
|
|
|
|
|
|
|
invoke-direct {v0, v15}, Landroidx/work/impl/utils/futures/AbstractFuture;->removeWaiter(Landroidx/work/impl/utils/futures/AbstractFuture$Waiter;)V
|
|
|
|
|
2019-08-30 20:04:20 +00:00
|
|
|
goto :goto_3
|
2019-07-24 11:27:29 +00:00
|
|
|
|
2019-08-30 20:04:20 +00:00
|
|
|
:cond_7
|
2019-07-24 11:27:29 +00:00
|
|
|
invoke-direct {v0, v15}, Landroidx/work/impl/utils/futures/AbstractFuture;->removeWaiter(Landroidx/work/impl/utils/futures/AbstractFuture$Waiter;)V
|
|
|
|
|
|
|
|
new-instance v1, Ljava/lang/InterruptedException;
|
|
|
|
|
|
|
|
invoke-direct {v1}, Ljava/lang/InterruptedException;-><init>()V
|
|
|
|
|
|
|
|
throw v1
|
|
|
|
|
2019-08-30 20:04:20 +00:00
|
|
|
:cond_8
|
2019-07-24 11:27:29 +00:00
|
|
|
iget-object v6, v0, Landroidx/work/impl/utils/futures/AbstractFuture;->waiters:Landroidx/work/impl/utils/futures/AbstractFuture$Waiter;
|
|
|
|
|
|
|
|
sget-object v7, Landroidx/work/impl/utils/futures/AbstractFuture$Waiter;->TOMBSTONE:Landroidx/work/impl/utils/futures/AbstractFuture$Waiter;
|
|
|
|
|
2019-08-30 20:04:20 +00:00
|
|
|
if-ne v6, v7, :cond_3
|
2019-07-24 11:27:29 +00:00
|
|
|
|
2019-08-30 20:04:20 +00:00
|
|
|
:cond_9
|
2019-07-24 11:27:29 +00:00
|
|
|
iget-object v1, v0, Landroidx/work/impl/utils/futures/AbstractFuture;->value:Ljava/lang/Object;
|
|
|
|
|
|
|
|
invoke-direct {v0, v1}, Landroidx/work/impl/utils/futures/AbstractFuture;->getDoneValue(Ljava/lang/Object;)Ljava/lang/Object;
|
|
|
|
|
|
|
|
move-result-object v1
|
|
|
|
|
|
|
|
return-object v1
|
|
|
|
|
2019-08-30 20:04:20 +00:00
|
|
|
:cond_a
|
|
|
|
:goto_3
|
2019-07-24 11:27:29 +00:00
|
|
|
cmp-long v6, v4, v9
|
|
|
|
|
2019-08-30 20:04:20 +00:00
|
|
|
if-lez v6, :cond_e
|
2019-07-24 11:27:29 +00:00
|
|
|
|
|
|
|
iget-object v4, v0, Landroidx/work/impl/utils/futures/AbstractFuture;->value:Ljava/lang/Object;
|
|
|
|
|
2019-08-30 20:04:20 +00:00
|
|
|
if-eqz v4, :cond_b
|
2019-07-24 11:27:29 +00:00
|
|
|
|
|
|
|
const/4 v5, 0x1
|
|
|
|
|
2019-08-30 20:04:20 +00:00
|
|
|
goto :goto_4
|
2019-07-24 11:27:29 +00:00
|
|
|
|
2019-08-30 20:04:20 +00:00
|
|
|
:cond_b
|
2019-07-24 11:27:29 +00:00
|
|
|
const/4 v5, 0x0
|
|
|
|
|
2019-08-30 20:04:20 +00:00
|
|
|
:goto_4
|
2019-07-24 11:27:29 +00:00
|
|
|
instance-of v6, v4, Landroidx/work/impl/utils/futures/AbstractFuture$SetFuture;
|
|
|
|
|
2019-08-30 20:04:20 +00:00
|
|
|
xor-int/2addr v6, v8
|
2019-07-24 11:27:29 +00:00
|
|
|
|
|
|
|
and-int/2addr v5, v6
|
|
|
|
|
2019-08-30 20:04:20 +00:00
|
|
|
if-eqz v5, :cond_c
|
2019-07-24 11:27:29 +00:00
|
|
|
|
|
|
|
invoke-direct {v0, v4}, Landroidx/work/impl/utils/futures/AbstractFuture;->getDoneValue(Ljava/lang/Object;)Ljava/lang/Object;
|
|
|
|
|
|
|
|
move-result-object v1
|
|
|
|
|
|
|
|
return-object v1
|
|
|
|
|
2019-08-30 20:04:20 +00:00
|
|
|
:cond_c
|
2019-07-24 11:27:29 +00:00
|
|
|
invoke-static {}, Ljava/lang/Thread;->interrupted()Z
|
|
|
|
|
|
|
|
move-result v4
|
|
|
|
|
2019-08-30 20:04:20 +00:00
|
|
|
if-nez v4, :cond_d
|
2019-07-24 11:27:29 +00:00
|
|
|
|
|
|
|
invoke-static {}, Ljava/lang/System;->nanoTime()J
|
|
|
|
|
|
|
|
move-result-wide v4
|
|
|
|
|
|
|
|
sub-long v4, v11, v4
|
|
|
|
|
2019-08-30 20:04:20 +00:00
|
|
|
goto :goto_3
|
2019-07-24 11:27:29 +00:00
|
|
|
|
2019-08-30 20:04:20 +00:00
|
|
|
:cond_d
|
2019-07-24 11:27:29 +00:00
|
|
|
new-instance v1, Ljava/lang/InterruptedException;
|
|
|
|
|
|
|
|
invoke-direct {v1}, Ljava/lang/InterruptedException;-><init>()V
|
|
|
|
|
|
|
|
throw v1
|
|
|
|
|
2019-08-30 20:04:20 +00:00
|
|
|
:cond_e
|
2019-07-24 11:27:29 +00:00
|
|
|
invoke-virtual/range {p0 .. p0}, Landroidx/work/impl/utils/futures/AbstractFuture;->toString()Ljava/lang/String;
|
|
|
|
|
|
|
|
move-result-object v6
|
|
|
|
|
|
|
|
invoke-virtual/range {p3 .. p3}, Ljava/util/concurrent/TimeUnit;->toString()Ljava/lang/String;
|
|
|
|
|
|
|
|
move-result-object v7
|
|
|
|
|
|
|
|
sget-object v11, Ljava/util/Locale;->ROOT:Ljava/util/Locale;
|
|
|
|
|
|
|
|
invoke-virtual {v7, v11}, Ljava/lang/String;->toLowerCase(Ljava/util/Locale;)Ljava/lang/String;
|
|
|
|
|
|
|
|
move-result-object v7
|
|
|
|
|
|
|
|
new-instance v11, Ljava/lang/StringBuilder;
|
|
|
|
|
|
|
|
const-string v12, "Waited "
|
|
|
|
|
|
|
|
invoke-direct {v11, v12}, Ljava/lang/StringBuilder;-><init>(Ljava/lang/String;)V
|
|
|
|
|
|
|
|
invoke-virtual {v11, v1, v2}, Ljava/lang/StringBuilder;->append(J)Ljava/lang/StringBuilder;
|
|
|
|
|
|
|
|
const-string v1, " "
|
|
|
|
|
|
|
|
invoke-virtual {v11, v1}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;
|
|
|
|
|
|
|
|
invoke-virtual/range {p3 .. p3}, Ljava/util/concurrent/TimeUnit;->toString()Ljava/lang/String;
|
|
|
|
|
|
|
|
move-result-object v2
|
|
|
|
|
|
|
|
sget-object v12, Ljava/util/Locale;->ROOT:Ljava/util/Locale;
|
|
|
|
|
|
|
|
invoke-virtual {v2, v12}, Ljava/lang/String;->toLowerCase(Ljava/util/Locale;)Ljava/lang/String;
|
|
|
|
|
|
|
|
move-result-object v2
|
|
|
|
|
|
|
|
invoke-virtual {v11, v2}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;
|
|
|
|
|
|
|
|
invoke-virtual {v11}, Ljava/lang/StringBuilder;->toString()Ljava/lang/String;
|
|
|
|
|
|
|
|
move-result-object v2
|
|
|
|
|
|
|
|
add-long v11, v4, v13
|
|
|
|
|
|
|
|
cmp-long v15, v11, v9
|
|
|
|
|
2019-08-30 20:04:20 +00:00
|
|
|
if-gez v15, :cond_14
|
2019-07-24 11:27:29 +00:00
|
|
|
|
|
|
|
new-instance v11, Ljava/lang/StringBuilder;
|
|
|
|
|
|
|
|
invoke-direct {v11}, Ljava/lang/StringBuilder;-><init>()V
|
|
|
|
|
|
|
|
invoke-virtual {v11, v2}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;
|
|
|
|
|
|
|
|
const-string v2, " (plus "
|
|
|
|
|
|
|
|
invoke-virtual {v11, v2}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;
|
|
|
|
|
|
|
|
invoke-virtual {v11}, Ljava/lang/StringBuilder;->toString()Ljava/lang/String;
|
|
|
|
|
|
|
|
move-result-object v2
|
|
|
|
|
|
|
|
neg-long v4, v4
|
|
|
|
|
|
|
|
sget-object v11, Ljava/util/concurrent/TimeUnit;->NANOSECONDS:Ljava/util/concurrent/TimeUnit;
|
|
|
|
|
|
|
|
invoke-virtual {v3, v4, v5, v11}, Ljava/util/concurrent/TimeUnit;->convert(JLjava/util/concurrent/TimeUnit;)J
|
|
|
|
|
|
|
|
move-result-wide v11
|
|
|
|
|
|
|
|
invoke-virtual {v3, v11, v12}, Ljava/util/concurrent/TimeUnit;->toNanos(J)J
|
|
|
|
|
|
|
|
move-result-wide v17
|
|
|
|
|
|
|
|
sub-long v4, v4, v17
|
|
|
|
|
|
|
|
cmp-long v3, v11, v9
|
|
|
|
|
2019-08-30 20:04:20 +00:00
|
|
|
if-eqz v3, :cond_10
|
2019-07-24 11:27:29 +00:00
|
|
|
|
2019-11-20 22:09:14 +00:00
|
|
|
cmp-long v9, v4, v13
|
2019-07-24 11:27:29 +00:00
|
|
|
|
2019-11-20 22:09:14 +00:00
|
|
|
if-lez v9, :cond_f
|
2019-07-24 11:27:29 +00:00
|
|
|
|
2019-08-30 20:04:20 +00:00
|
|
|
goto :goto_5
|
2019-07-24 11:27:29 +00:00
|
|
|
|
2019-08-30 20:04:20 +00:00
|
|
|
:cond_f
|
2019-07-24 11:27:29 +00:00
|
|
|
const/16 v16, 0x0
|
|
|
|
|
2019-08-30 20:04:20 +00:00
|
|
|
goto :goto_6
|
2019-07-24 11:27:29 +00:00
|
|
|
|
2019-08-30 20:04:20 +00:00
|
|
|
:cond_10
|
|
|
|
:goto_5
|
2019-07-24 11:27:29 +00:00
|
|
|
const/16 v16, 0x1
|
|
|
|
|
2019-08-30 20:04:20 +00:00
|
|
|
:goto_6
|
|
|
|
if-lez v3, :cond_12
|
2019-07-24 11:27:29 +00:00
|
|
|
|
|
|
|
new-instance v3, Ljava/lang/StringBuilder;
|
|
|
|
|
|
|
|
invoke-direct {v3}, Ljava/lang/StringBuilder;-><init>()V
|
|
|
|
|
|
|
|
invoke-virtual {v3, v2}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;
|
|
|
|
|
|
|
|
invoke-virtual {v3, v11, v12}, Ljava/lang/StringBuilder;->append(J)Ljava/lang/StringBuilder;
|
|
|
|
|
|
|
|
invoke-virtual {v3, v1}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;
|
|
|
|
|
|
|
|
invoke-virtual {v3, v7}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;
|
|
|
|
|
|
|
|
invoke-virtual {v3}, Ljava/lang/StringBuilder;->toString()Ljava/lang/String;
|
|
|
|
|
|
|
|
move-result-object v2
|
|
|
|
|
2019-08-30 20:04:20 +00:00
|
|
|
if-eqz v16, :cond_11
|
2019-07-24 11:27:29 +00:00
|
|
|
|
|
|
|
new-instance v3, Ljava/lang/StringBuilder;
|
|
|
|
|
|
|
|
invoke-direct {v3}, Ljava/lang/StringBuilder;-><init>()V
|
|
|
|
|
|
|
|
invoke-virtual {v3, v2}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;
|
|
|
|
|
|
|
|
const-string v2, ","
|
|
|
|
|
|
|
|
invoke-virtual {v3, v2}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;
|
|
|
|
|
|
|
|
invoke-virtual {v3}, Ljava/lang/StringBuilder;->toString()Ljava/lang/String;
|
|
|
|
|
|
|
|
move-result-object v2
|
|
|
|
|
2019-08-30 20:04:20 +00:00
|
|
|
:cond_11
|
2019-07-24 11:27:29 +00:00
|
|
|
new-instance v3, Ljava/lang/StringBuilder;
|
|
|
|
|
|
|
|
invoke-direct {v3}, Ljava/lang/StringBuilder;-><init>()V
|
|
|
|
|
|
|
|
invoke-virtual {v3, v2}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;
|
|
|
|
|
|
|
|
invoke-virtual {v3, v1}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;
|
|
|
|
|
|
|
|
invoke-virtual {v3}, Ljava/lang/StringBuilder;->toString()Ljava/lang/String;
|
|
|
|
|
|
|
|
move-result-object v2
|
|
|
|
|
2019-08-30 20:04:20 +00:00
|
|
|
:cond_12
|
|
|
|
if-eqz v16, :cond_13
|
2019-07-24 11:27:29 +00:00
|
|
|
|
|
|
|
new-instance v1, Ljava/lang/StringBuilder;
|
|
|
|
|
|
|
|
invoke-direct {v1}, Ljava/lang/StringBuilder;-><init>()V
|
|
|
|
|
|
|
|
invoke-virtual {v1, v2}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;
|
|
|
|
|
|
|
|
invoke-virtual {v1, v4, v5}, Ljava/lang/StringBuilder;->append(J)Ljava/lang/StringBuilder;
|
|
|
|
|
|
|
|
const-string v2, " nanoseconds "
|
|
|
|
|
|
|
|
invoke-virtual {v1, v2}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;
|
|
|
|
|
|
|
|
invoke-virtual {v1}, Ljava/lang/StringBuilder;->toString()Ljava/lang/String;
|
|
|
|
|
|
|
|
move-result-object v2
|
|
|
|
|
2019-08-30 20:04:20 +00:00
|
|
|
:cond_13
|
2019-07-24 11:27:29 +00:00
|
|
|
new-instance v1, Ljava/lang/StringBuilder;
|
|
|
|
|
|
|
|
invoke-direct {v1}, Ljava/lang/StringBuilder;-><init>()V
|
|
|
|
|
|
|
|
invoke-virtual {v1, v2}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;
|
|
|
|
|
|
|
|
const-string v2, "delay)"
|
|
|
|
|
|
|
|
invoke-virtual {v1, v2}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;
|
|
|
|
|
|
|
|
invoke-virtual {v1}, Ljava/lang/StringBuilder;->toString()Ljava/lang/String;
|
|
|
|
|
|
|
|
move-result-object v2
|
|
|
|
|
2019-08-30 20:04:20 +00:00
|
|
|
:cond_14
|
2019-07-24 11:27:29 +00:00
|
|
|
invoke-virtual/range {p0 .. p0}, Landroidx/work/impl/utils/futures/AbstractFuture;->isDone()Z
|
|
|
|
|
|
|
|
move-result v1
|
|
|
|
|
2019-08-30 20:04:20 +00:00
|
|
|
if-eqz v1, :cond_15
|
2019-07-24 11:27:29 +00:00
|
|
|
|
|
|
|
new-instance v1, Ljava/util/concurrent/TimeoutException;
|
|
|
|
|
|
|
|
new-instance v3, Ljava/lang/StringBuilder;
|
|
|
|
|
|
|
|
invoke-direct {v3}, Ljava/lang/StringBuilder;-><init>()V
|
|
|
|
|
|
|
|
invoke-virtual {v3, v2}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;
|
|
|
|
|
|
|
|
const-string v2, " but future completed as timeout expired"
|
|
|
|
|
|
|
|
invoke-virtual {v3, v2}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;
|
|
|
|
|
|
|
|
invoke-virtual {v3}, Ljava/lang/StringBuilder;->toString()Ljava/lang/String;
|
|
|
|
|
|
|
|
move-result-object v2
|
|
|
|
|
|
|
|
invoke-direct {v1, v2}, Ljava/util/concurrent/TimeoutException;-><init>(Ljava/lang/String;)V
|
|
|
|
|
|
|
|
throw v1
|
|
|
|
|
2019-08-30 20:04:20 +00:00
|
|
|
:cond_15
|
2019-07-24 11:27:29 +00:00
|
|
|
new-instance v1, Ljava/util/concurrent/TimeoutException;
|
|
|
|
|
|
|
|
new-instance v3, Ljava/lang/StringBuilder;
|
|
|
|
|
|
|
|
invoke-direct {v3}, Ljava/lang/StringBuilder;-><init>()V
|
|
|
|
|
|
|
|
invoke-virtual {v3, v2}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;
|
|
|
|
|
|
|
|
const-string v2, " for "
|
|
|
|
|
|
|
|
invoke-virtual {v3, v2}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;
|
|
|
|
|
|
|
|
invoke-virtual {v3, v6}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;
|
|
|
|
|
|
|
|
invoke-virtual {v3}, Ljava/lang/StringBuilder;->toString()Ljava/lang/String;
|
|
|
|
|
|
|
|
move-result-object v2
|
|
|
|
|
|
|
|
invoke-direct {v1, v2}, Ljava/util/concurrent/TimeoutException;-><init>(Ljava/lang/String;)V
|
|
|
|
|
|
|
|
throw v1
|
|
|
|
|
2019-08-30 20:04:20 +00:00
|
|
|
:cond_16
|
2019-07-24 11:27:29 +00:00
|
|
|
new-instance v1, Ljava/lang/InterruptedException;
|
|
|
|
|
|
|
|
invoke-direct {v1}, Ljava/lang/InterruptedException;-><init>()V
|
|
|
|
|
|
|
|
throw v1
|
|
|
|
.end method
|
|
|
|
|
|
|
|
.method protected interruptTask()V
|
|
|
|
.locals 0
|
|
|
|
|
|
|
|
return-void
|
|
|
|
.end method
|
|
|
|
|
|
|
|
.method public final isCancelled()Z
|
|
|
|
.locals 1
|
|
|
|
|
|
|
|
iget-object v0, p0, Landroidx/work/impl/utils/futures/AbstractFuture;->value:Ljava/lang/Object;
|
|
|
|
|
|
|
|
instance-of v0, v0, Landroidx/work/impl/utils/futures/AbstractFuture$Cancellation;
|
|
|
|
|
|
|
|
return v0
|
|
|
|
.end method
|
|
|
|
|
|
|
|
.method public final isDone()Z
|
2019-08-30 20:04:20 +00:00
|
|
|
.locals 3
|
2019-07-24 11:27:29 +00:00
|
|
|
|
|
|
|
iget-object v0, p0, Landroidx/work/impl/utils/futures/AbstractFuture;->value:Ljava/lang/Object;
|
|
|
|
|
|
|
|
const/4 v1, 0x1
|
|
|
|
|
|
|
|
if-eqz v0, :cond_0
|
|
|
|
|
2019-08-30 20:04:20 +00:00
|
|
|
const/4 v2, 0x1
|
2019-07-24 11:27:29 +00:00
|
|
|
|
|
|
|
goto :goto_0
|
|
|
|
|
|
|
|
:cond_0
|
2019-08-30 20:04:20 +00:00
|
|
|
const/4 v2, 0x0
|
2019-07-24 11:27:29 +00:00
|
|
|
|
|
|
|
:goto_0
|
|
|
|
instance-of v0, v0, Landroidx/work/impl/utils/futures/AbstractFuture$SetFuture;
|
|
|
|
|
2019-08-30 20:04:20 +00:00
|
|
|
xor-int/2addr v0, v1
|
2019-07-24 11:27:29 +00:00
|
|
|
|
2019-08-30 20:04:20 +00:00
|
|
|
and-int/2addr v0, v2
|
2019-07-24 11:27:29 +00:00
|
|
|
|
|
|
|
return v0
|
|
|
|
.end method
|
|
|
|
|
|
|
|
.method final maybePropagateCancellationTo(Ljava/util/concurrent/Future;)V
|
|
|
|
.locals 2
|
|
|
|
.annotation system Ldalvik/annotation/Signature;
|
|
|
|
value = {
|
|
|
|
"(",
|
|
|
|
"Ljava/util/concurrent/Future<",
|
|
|
|
"*>;)V"
|
|
|
|
}
|
|
|
|
.end annotation
|
|
|
|
|
|
|
|
if-eqz p1, :cond_0
|
|
|
|
|
|
|
|
const/4 v0, 0x1
|
|
|
|
|
|
|
|
goto :goto_0
|
|
|
|
|
|
|
|
:cond_0
|
|
|
|
const/4 v0, 0x0
|
|
|
|
|
|
|
|
:goto_0
|
|
|
|
invoke-virtual {p0}, Landroidx/work/impl/utils/futures/AbstractFuture;->isCancelled()Z
|
|
|
|
|
|
|
|
move-result v1
|
|
|
|
|
|
|
|
and-int/2addr v0, v1
|
|
|
|
|
|
|
|
if-eqz v0, :cond_1
|
|
|
|
|
|
|
|
invoke-virtual {p0}, Landroidx/work/impl/utils/futures/AbstractFuture;->wasInterrupted()Z
|
|
|
|
|
|
|
|
move-result v0
|
|
|
|
|
|
|
|
invoke-interface {p1, v0}, Ljava/util/concurrent/Future;->cancel(Z)Z
|
|
|
|
|
|
|
|
:cond_1
|
|
|
|
return-void
|
|
|
|
.end method
|
|
|
|
|
|
|
|
.method protected pendingToString()Ljava/lang/String;
|
|
|
|
.locals 3
|
|
|
|
|
|
|
|
iget-object v0, p0, Landroidx/work/impl/utils/futures/AbstractFuture;->value:Ljava/lang/Object;
|
|
|
|
|
|
|
|
instance-of v1, v0, Landroidx/work/impl/utils/futures/AbstractFuture$SetFuture;
|
|
|
|
|
|
|
|
if-eqz v1, :cond_0
|
|
|
|
|
|
|
|
new-instance v1, Ljava/lang/StringBuilder;
|
|
|
|
|
|
|
|
const-string v2, "setFuture=["
|
|
|
|
|
|
|
|
invoke-direct {v1, v2}, Ljava/lang/StringBuilder;-><init>(Ljava/lang/String;)V
|
|
|
|
|
|
|
|
check-cast v0, Landroidx/work/impl/utils/futures/AbstractFuture$SetFuture;
|
|
|
|
|
|
|
|
iget-object v0, v0, Landroidx/work/impl/utils/futures/AbstractFuture$SetFuture;->future:Lcom/google/a/a/a/a;
|
|
|
|
|
|
|
|
invoke-direct {p0, v0}, Landroidx/work/impl/utils/futures/AbstractFuture;->userObjectToString(Ljava/lang/Object;)Ljava/lang/String;
|
|
|
|
|
|
|
|
move-result-object v0
|
|
|
|
|
|
|
|
invoke-virtual {v1, v0}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;
|
|
|
|
|
|
|
|
const-string v0, "]"
|
|
|
|
|
|
|
|
invoke-virtual {v1, v0}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;
|
|
|
|
|
|
|
|
invoke-virtual {v1}, Ljava/lang/StringBuilder;->toString()Ljava/lang/String;
|
|
|
|
|
|
|
|
move-result-object v0
|
|
|
|
|
|
|
|
return-object v0
|
|
|
|
|
|
|
|
:cond_0
|
|
|
|
instance-of v0, p0, Ljava/util/concurrent/ScheduledFuture;
|
|
|
|
|
|
|
|
if-eqz v0, :cond_1
|
|
|
|
|
|
|
|
new-instance v0, Ljava/lang/StringBuilder;
|
|
|
|
|
|
|
|
const-string v1, "remaining delay=["
|
|
|
|
|
|
|
|
invoke-direct {v0, v1}, Ljava/lang/StringBuilder;-><init>(Ljava/lang/String;)V
|
|
|
|
|
|
|
|
move-object v1, p0
|
|
|
|
|
|
|
|
check-cast v1, Ljava/util/concurrent/ScheduledFuture;
|
|
|
|
|
|
|
|
sget-object v2, Ljava/util/concurrent/TimeUnit;->MILLISECONDS:Ljava/util/concurrent/TimeUnit;
|
|
|
|
|
|
|
|
invoke-interface {v1, v2}, Ljava/util/concurrent/ScheduledFuture;->getDelay(Ljava/util/concurrent/TimeUnit;)J
|
|
|
|
|
|
|
|
move-result-wide v1
|
|
|
|
|
|
|
|
invoke-virtual {v0, v1, v2}, Ljava/lang/StringBuilder;->append(J)Ljava/lang/StringBuilder;
|
|
|
|
|
|
|
|
const-string v1, " ms]"
|
|
|
|
|
|
|
|
invoke-virtual {v0, v1}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;
|
|
|
|
|
|
|
|
invoke-virtual {v0}, Ljava/lang/StringBuilder;->toString()Ljava/lang/String;
|
|
|
|
|
|
|
|
move-result-object v0
|
|
|
|
|
|
|
|
return-object v0
|
|
|
|
|
|
|
|
:cond_1
|
|
|
|
const/4 v0, 0x0
|
|
|
|
|
|
|
|
return-object v0
|
|
|
|
.end method
|
|
|
|
|
|
|
|
.method protected set(Ljava/lang/Object;)Z
|
|
|
|
.locals 2
|
|
|
|
.annotation system Ldalvik/annotation/Signature;
|
|
|
|
value = {
|
|
|
|
"(TV;)Z"
|
|
|
|
}
|
|
|
|
.end annotation
|
|
|
|
|
|
|
|
if-nez p1, :cond_0
|
|
|
|
|
|
|
|
sget-object p1, Landroidx/work/impl/utils/futures/AbstractFuture;->NULL:Ljava/lang/Object;
|
|
|
|
|
|
|
|
:cond_0
|
|
|
|
sget-object v0, Landroidx/work/impl/utils/futures/AbstractFuture;->ATOMIC_HELPER:Landroidx/work/impl/utils/futures/AbstractFuture$AtomicHelper;
|
|
|
|
|
|
|
|
const/4 v1, 0x0
|
|
|
|
|
|
|
|
invoke-virtual {v0, p0, v1, p1}, Landroidx/work/impl/utils/futures/AbstractFuture$AtomicHelper;->casValue(Landroidx/work/impl/utils/futures/AbstractFuture;Ljava/lang/Object;Ljava/lang/Object;)Z
|
|
|
|
|
|
|
|
move-result p1
|
|
|
|
|
|
|
|
if-eqz p1, :cond_1
|
|
|
|
|
|
|
|
invoke-static {p0}, Landroidx/work/impl/utils/futures/AbstractFuture;->complete(Landroidx/work/impl/utils/futures/AbstractFuture;)V
|
|
|
|
|
|
|
|
const/4 p1, 0x1
|
|
|
|
|
|
|
|
return p1
|
|
|
|
|
|
|
|
:cond_1
|
|
|
|
const/4 p1, 0x0
|
|
|
|
|
|
|
|
return p1
|
|
|
|
.end method
|
|
|
|
|
|
|
|
.method protected setException(Ljava/lang/Throwable;)Z
|
|
|
|
.locals 2
|
|
|
|
|
|
|
|
new-instance v0, Landroidx/work/impl/utils/futures/AbstractFuture$Failure;
|
|
|
|
|
|
|
|
invoke-static {p1}, Landroidx/work/impl/utils/futures/AbstractFuture;->checkNotNull(Ljava/lang/Object;)Ljava/lang/Object;
|
|
|
|
|
|
|
|
move-result-object p1
|
|
|
|
|
|
|
|
check-cast p1, Ljava/lang/Throwable;
|
|
|
|
|
|
|
|
invoke-direct {v0, p1}, Landroidx/work/impl/utils/futures/AbstractFuture$Failure;-><init>(Ljava/lang/Throwable;)V
|
|
|
|
|
|
|
|
sget-object p1, Landroidx/work/impl/utils/futures/AbstractFuture;->ATOMIC_HELPER:Landroidx/work/impl/utils/futures/AbstractFuture$AtomicHelper;
|
|
|
|
|
|
|
|
const/4 v1, 0x0
|
|
|
|
|
|
|
|
invoke-virtual {p1, p0, v1, v0}, Landroidx/work/impl/utils/futures/AbstractFuture$AtomicHelper;->casValue(Landroidx/work/impl/utils/futures/AbstractFuture;Ljava/lang/Object;Ljava/lang/Object;)Z
|
|
|
|
|
|
|
|
move-result p1
|
|
|
|
|
|
|
|
if-eqz p1, :cond_0
|
|
|
|
|
|
|
|
invoke-static {p0}, Landroidx/work/impl/utils/futures/AbstractFuture;->complete(Landroidx/work/impl/utils/futures/AbstractFuture;)V
|
|
|
|
|
|
|
|
const/4 p1, 0x1
|
|
|
|
|
|
|
|
return p1
|
|
|
|
|
|
|
|
:cond_0
|
|
|
|
const/4 p1, 0x0
|
|
|
|
|
|
|
|
return p1
|
|
|
|
.end method
|
|
|
|
|
|
|
|
.method protected setFuture(Lcom/google/a/a/a/a;)Z
|
|
|
|
.locals 5
|
|
|
|
.annotation system Ldalvik/annotation/Signature;
|
|
|
|
value = {
|
|
|
|
"(",
|
|
|
|
"Lcom/google/a/a/a/a<",
|
|
|
|
"+TV;>;)Z"
|
|
|
|
}
|
|
|
|
.end annotation
|
|
|
|
|
|
|
|
invoke-static {p1}, Landroidx/work/impl/utils/futures/AbstractFuture;->checkNotNull(Ljava/lang/Object;)Ljava/lang/Object;
|
|
|
|
|
|
|
|
iget-object v0, p0, Landroidx/work/impl/utils/futures/AbstractFuture;->value:Ljava/lang/Object;
|
|
|
|
|
|
|
|
const/4 v1, 0x0
|
|
|
|
|
|
|
|
if-nez v0, :cond_3
|
|
|
|
|
|
|
|
invoke-interface {p1}, Lcom/google/a/a/a/a;->isDone()Z
|
|
|
|
|
|
|
|
move-result v0
|
|
|
|
|
|
|
|
const/4 v2, 0x1
|
|
|
|
|
|
|
|
const/4 v3, 0x0
|
|
|
|
|
|
|
|
if-eqz v0, :cond_1
|
|
|
|
|
|
|
|
invoke-static {p1}, Landroidx/work/impl/utils/futures/AbstractFuture;->getFutureValue(Lcom/google/a/a/a/a;)Ljava/lang/Object;
|
|
|
|
|
|
|
|
move-result-object p1
|
|
|
|
|
|
|
|
sget-object v0, Landroidx/work/impl/utils/futures/AbstractFuture;->ATOMIC_HELPER:Landroidx/work/impl/utils/futures/AbstractFuture$AtomicHelper;
|
|
|
|
|
|
|
|
invoke-virtual {v0, p0, v3, p1}, Landroidx/work/impl/utils/futures/AbstractFuture$AtomicHelper;->casValue(Landroidx/work/impl/utils/futures/AbstractFuture;Ljava/lang/Object;Ljava/lang/Object;)Z
|
|
|
|
|
|
|
|
move-result p1
|
|
|
|
|
|
|
|
if-eqz p1, :cond_0
|
|
|
|
|
|
|
|
invoke-static {p0}, Landroidx/work/impl/utils/futures/AbstractFuture;->complete(Landroidx/work/impl/utils/futures/AbstractFuture;)V
|
|
|
|
|
|
|
|
return v2
|
|
|
|
|
|
|
|
:cond_0
|
|
|
|
return v1
|
|
|
|
|
|
|
|
:cond_1
|
|
|
|
new-instance v0, Landroidx/work/impl/utils/futures/AbstractFuture$SetFuture;
|
|
|
|
|
|
|
|
invoke-direct {v0, p0, p1}, Landroidx/work/impl/utils/futures/AbstractFuture$SetFuture;-><init>(Landroidx/work/impl/utils/futures/AbstractFuture;Lcom/google/a/a/a/a;)V
|
|
|
|
|
|
|
|
sget-object v4, Landroidx/work/impl/utils/futures/AbstractFuture;->ATOMIC_HELPER:Landroidx/work/impl/utils/futures/AbstractFuture$AtomicHelper;
|
|
|
|
|
|
|
|
invoke-virtual {v4, p0, v3, v0}, Landroidx/work/impl/utils/futures/AbstractFuture$AtomicHelper;->casValue(Landroidx/work/impl/utils/futures/AbstractFuture;Ljava/lang/Object;Ljava/lang/Object;)Z
|
|
|
|
|
|
|
|
move-result v3
|
|
|
|
|
|
|
|
if-eqz v3, :cond_2
|
|
|
|
|
|
|
|
:try_start_0
|
|
|
|
sget-object v1, Landroidx/work/impl/utils/futures/DirectExecutor;->INSTANCE:Landroidx/work/impl/utils/futures/DirectExecutor;
|
|
|
|
|
|
|
|
invoke-interface {p1, v0, v1}, Lcom/google/a/a/a/a;->addListener(Ljava/lang/Runnable;Ljava/util/concurrent/Executor;)V
|
|
|
|
:try_end_0
|
2019-08-30 20:04:20 +00:00
|
|
|
.catchall {:try_start_0 .. :try_end_0} :catchall_0
|
2019-07-24 11:27:29 +00:00
|
|
|
|
|
|
|
goto :goto_1
|
|
|
|
|
2019-08-30 20:04:20 +00:00
|
|
|
:catchall_0
|
2019-07-24 11:27:29 +00:00
|
|
|
move-exception p1
|
|
|
|
|
|
|
|
:try_start_1
|
|
|
|
new-instance v1, Landroidx/work/impl/utils/futures/AbstractFuture$Failure;
|
|
|
|
|
|
|
|
invoke-direct {v1, p1}, Landroidx/work/impl/utils/futures/AbstractFuture$Failure;-><init>(Ljava/lang/Throwable;)V
|
|
|
|
:try_end_1
|
2019-08-30 20:04:20 +00:00
|
|
|
.catchall {:try_start_1 .. :try_end_1} :catchall_1
|
2019-07-24 11:27:29 +00:00
|
|
|
|
|
|
|
goto :goto_0
|
|
|
|
|
2019-08-30 20:04:20 +00:00
|
|
|
:catchall_1
|
2019-07-24 11:27:29 +00:00
|
|
|
sget-object v1, Landroidx/work/impl/utils/futures/AbstractFuture$Failure;->FALLBACK_INSTANCE:Landroidx/work/impl/utils/futures/AbstractFuture$Failure;
|
|
|
|
|
|
|
|
:goto_0
|
|
|
|
sget-object p1, Landroidx/work/impl/utils/futures/AbstractFuture;->ATOMIC_HELPER:Landroidx/work/impl/utils/futures/AbstractFuture$AtomicHelper;
|
|
|
|
|
|
|
|
invoke-virtual {p1, p0, v0, v1}, Landroidx/work/impl/utils/futures/AbstractFuture$AtomicHelper;->casValue(Landroidx/work/impl/utils/futures/AbstractFuture;Ljava/lang/Object;Ljava/lang/Object;)Z
|
|
|
|
|
|
|
|
:goto_1
|
|
|
|
return v2
|
|
|
|
|
|
|
|
:cond_2
|
|
|
|
iget-object v0, p0, Landroidx/work/impl/utils/futures/AbstractFuture;->value:Ljava/lang/Object;
|
|
|
|
|
|
|
|
:cond_3
|
|
|
|
instance-of v2, v0, Landroidx/work/impl/utils/futures/AbstractFuture$Cancellation;
|
|
|
|
|
|
|
|
if-eqz v2, :cond_4
|
|
|
|
|
|
|
|
check-cast v0, Landroidx/work/impl/utils/futures/AbstractFuture$Cancellation;
|
|
|
|
|
|
|
|
iget-boolean v0, v0, Landroidx/work/impl/utils/futures/AbstractFuture$Cancellation;->wasInterrupted:Z
|
|
|
|
|
|
|
|
invoke-interface {p1, v0}, Lcom/google/a/a/a/a;->cancel(Z)Z
|
|
|
|
|
|
|
|
:cond_4
|
|
|
|
return v1
|
|
|
|
.end method
|
|
|
|
|
|
|
|
.method public toString()Ljava/lang/String;
|
|
|
|
.locals 5
|
|
|
|
|
|
|
|
new-instance v0, Ljava/lang/StringBuilder;
|
|
|
|
|
|
|
|
invoke-direct {v0}, Ljava/lang/StringBuilder;-><init>()V
|
|
|
|
|
|
|
|
invoke-super {p0}, Ljava/lang/Object;->toString()Ljava/lang/String;
|
|
|
|
|
|
|
|
move-result-object v1
|
|
|
|
|
|
|
|
invoke-virtual {v0, v1}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;
|
|
|
|
|
|
|
|
const-string v1, "[status="
|
|
|
|
|
|
|
|
invoke-virtual {v0, v1}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;
|
|
|
|
|
|
|
|
invoke-virtual {p0}, Landroidx/work/impl/utils/futures/AbstractFuture;->isCancelled()Z
|
|
|
|
|
|
|
|
move-result v1
|
|
|
|
|
|
|
|
const-string v2, "]"
|
|
|
|
|
|
|
|
if-eqz v1, :cond_0
|
|
|
|
|
|
|
|
const-string v1, "CANCELLED"
|
|
|
|
|
|
|
|
invoke-virtual {v0, v1}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;
|
|
|
|
|
|
|
|
goto :goto_1
|
|
|
|
|
|
|
|
:cond_0
|
|
|
|
invoke-virtual {p0}, Landroidx/work/impl/utils/futures/AbstractFuture;->isDone()Z
|
|
|
|
|
|
|
|
move-result v1
|
|
|
|
|
|
|
|
if-eqz v1, :cond_1
|
|
|
|
|
|
|
|
invoke-direct {p0, v0}, Landroidx/work/impl/utils/futures/AbstractFuture;->addDoneString(Ljava/lang/StringBuilder;)V
|
|
|
|
|
|
|
|
goto :goto_1
|
|
|
|
|
|
|
|
:cond_1
|
|
|
|
:try_start_0
|
|
|
|
invoke-virtual {p0}, Landroidx/work/impl/utils/futures/AbstractFuture;->pendingToString()Ljava/lang/String;
|
|
|
|
|
|
|
|
move-result-object v1
|
|
|
|
:try_end_0
|
|
|
|
.catch Ljava/lang/RuntimeException; {:try_start_0 .. :try_end_0} :catch_0
|
|
|
|
|
|
|
|
goto :goto_0
|
|
|
|
|
|
|
|
:catch_0
|
|
|
|
move-exception v1
|
|
|
|
|
|
|
|
new-instance v3, Ljava/lang/StringBuilder;
|
|
|
|
|
|
|
|
const-string v4, "Exception thrown from implementation: "
|
|
|
|
|
|
|
|
invoke-direct {v3, v4}, Ljava/lang/StringBuilder;-><init>(Ljava/lang/String;)V
|
|
|
|
|
|
|
|
invoke-virtual {v1}, Ljava/lang/Object;->getClass()Ljava/lang/Class;
|
|
|
|
|
|
|
|
move-result-object v1
|
|
|
|
|
|
|
|
invoke-virtual {v3, v1}, Ljava/lang/StringBuilder;->append(Ljava/lang/Object;)Ljava/lang/StringBuilder;
|
|
|
|
|
|
|
|
invoke-virtual {v3}, Ljava/lang/StringBuilder;->toString()Ljava/lang/String;
|
|
|
|
|
|
|
|
move-result-object v1
|
|
|
|
|
|
|
|
:goto_0
|
|
|
|
if-eqz v1, :cond_2
|
|
|
|
|
|
|
|
invoke-virtual {v1}, Ljava/lang/String;->isEmpty()Z
|
|
|
|
|
|
|
|
move-result v3
|
|
|
|
|
|
|
|
if-nez v3, :cond_2
|
|
|
|
|
|
|
|
const-string v3, "PENDING, info=["
|
|
|
|
|
|
|
|
invoke-virtual {v0, v3}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;
|
|
|
|
|
|
|
|
invoke-virtual {v0, v1}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;
|
|
|
|
|
|
|
|
invoke-virtual {v0, v2}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;
|
|
|
|
|
|
|
|
goto :goto_1
|
|
|
|
|
|
|
|
:cond_2
|
|
|
|
invoke-virtual {p0}, Landroidx/work/impl/utils/futures/AbstractFuture;->isDone()Z
|
|
|
|
|
|
|
|
move-result v1
|
|
|
|
|
|
|
|
if-eqz v1, :cond_3
|
|
|
|
|
|
|
|
invoke-direct {p0, v0}, Landroidx/work/impl/utils/futures/AbstractFuture;->addDoneString(Ljava/lang/StringBuilder;)V
|
|
|
|
|
|
|
|
goto :goto_1
|
|
|
|
|
|
|
|
:cond_3
|
|
|
|
const-string v1, "PENDING"
|
|
|
|
|
|
|
|
invoke-virtual {v0, v1}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;
|
|
|
|
|
|
|
|
:goto_1
|
|
|
|
invoke-virtual {v0, v2}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;
|
|
|
|
|
|
|
|
invoke-virtual {v0}, Ljava/lang/StringBuilder;->toString()Ljava/lang/String;
|
|
|
|
|
|
|
|
move-result-object v0
|
|
|
|
|
|
|
|
return-object v0
|
|
|
|
.end method
|
|
|
|
|
|
|
|
.method protected final wasInterrupted()Z
|
|
|
|
.locals 2
|
|
|
|
|
|
|
|
iget-object v0, p0, Landroidx/work/impl/utils/futures/AbstractFuture;->value:Ljava/lang/Object;
|
|
|
|
|
|
|
|
instance-of v1, v0, Landroidx/work/impl/utils/futures/AbstractFuture$Cancellation;
|
|
|
|
|
|
|
|
if-eqz v1, :cond_0
|
|
|
|
|
|
|
|
check-cast v0, Landroidx/work/impl/utils/futures/AbstractFuture$Cancellation;
|
|
|
|
|
|
|
|
iget-boolean v0, v0, Landroidx/work/impl/utils/futures/AbstractFuture$Cancellation;->wasInterrupted:Z
|
|
|
|
|
|
|
|
if-eqz v0, :cond_0
|
|
|
|
|
|
|
|
const/4 v0, 0x1
|
|
|
|
|
|
|
|
return v0
|
|
|
|
|
|
|
|
:cond_0
|
|
|
|
const/4 v0, 0x0
|
|
|
|
|
|
|
|
return v0
|
|
|
|
.end method
|