.class public Lm3/m;
.super Ljava/lang/Object;
.source ""

# interfaces
.implements Lm3/i$a;
.implements Lh4/a$d;


# annotations
.annotation system Ldalvik/annotation/MemberClasses;
    value = {
        Lm3/m$c;,
        Lm3/m$d;,
        Lm3/m$e;,
        Lm3/m$b;,
        Lm3/m$a;
    }
.end annotation

.annotation system Ldalvik/annotation/Signature;
    value = {
        "<R:",
        "Ljava/lang/Object;",
        ">",
        "Ljava/lang/Object;",
        "Lm3/i$a<",
        "TR;>;",
        "Lh4/a$d;"
    }
.end annotation


# static fields
.field public static final Q:Lm3/m$c;


# instance fields
.field public final A:Lp3/a;

.field public final B:Ljava/util/concurrent/atomic/AtomicInteger;

.field public C:Lk3/c;

.field public D:Z

.field public E:Z

.field public F:Z

.field public G:Z

.field public H:Lm3/w;
    .annotation system Ldalvik/annotation/Signature;
        value = {
            "Lm3/w<",
            "*>;"
        }
    .end annotation
.end field

.field public I:Lcom/bumptech/glide/load/a;

.field public J:Z

.field public K:Lm3/r;

.field public L:Z

.field public M:Lm3/q;
    .annotation system Ldalvik/annotation/Signature;
        value = {
            "Lm3/q<",
            "*>;"
        }
    .end annotation
.end field

.field public N:Lm3/i;
    .annotation system Ldalvik/annotation/Signature;
        value = {
            "Lm3/i<",
            "TR;>;"
        }
    .end annotation
.end field

.field public volatile O:Z

.field public P:Z

.field public final r:Lm3/m$e;

.field public final s:Lh4/d;

.field public final t:Lm3/q$a;

.field public final u:Lk0/c;
    .annotation system Ldalvik/annotation/Signature;
        value = {
            "Lk0/c<",
            "Lm3/m<",
            "*>;>;"
        }
    .end annotation
.end field

.field public final v:Lm3/m$c;

.field public final w:Lm3/n;

.field public final x:Lp3/a;

.field public final y:Lp3/a;

.field public final z:Lp3/a;


# direct methods
.method public static constructor <clinit>()V
    .registers 1

    new-instance v0, Lm3/m$c;

    invoke-direct {v0}, Lm3/m$c;-><init>()V

    sput-object v0, Lm3/m;->Q:Lm3/m$c;

    return-void
.end method

.method public constructor <init>(Lp3/a;Lp3/a;Lp3/a;Lp3/a;Lm3/n;Lm3/q$a;Lk0/c;)V
    .registers 10
    .annotation system Ldalvik/annotation/Signature;
        value = {
            "(",
            "Lp3/a;",
            "Lp3/a;",
            "Lp3/a;",
            "Lp3/a;",
            "Lm3/n;",
            "Lm3/q$a;",
            "Lk0/c<",
            "Lm3/m<",
            "*>;>;)V"
        }
    .end annotation

    sget-object v0, Lm3/m;->Q:Lm3/m$c;

    .line 1
    invoke-direct {p0}, Ljava/lang/Object;-><init>()V

    new-instance v1, Lm3/m$e;

    invoke-direct {v1}, Lm3/m$e;-><init>()V

    iput-object v1, p0, Lm3/m;->r:Lm3/m$e;

    .line 2
    new-instance v1, Lh4/d$b;

    invoke-direct {v1}, Lh4/d$b;-><init>()V

    .line 3
    iput-object v1, p0, Lm3/m;->s:Lh4/d;

    new-instance v1, Ljava/util/concurrent/atomic/AtomicInteger;

    invoke-direct {v1}, Ljava/util/concurrent/atomic/AtomicInteger;-><init>()V

    iput-object v1, p0, Lm3/m;->B:Ljava/util/concurrent/atomic/AtomicInteger;

    iput-object p1, p0, Lm3/m;->x:Lp3/a;

    iput-object p2, p0, Lm3/m;->y:Lp3/a;

    iput-object p3, p0, Lm3/m;->z:Lp3/a;

    iput-object p4, p0, Lm3/m;->A:Lp3/a;

    iput-object p5, p0, Lm3/m;->w:Lm3/n;

    iput-object p6, p0, Lm3/m;->t:Lm3/q$a;

    iput-object p7, p0, Lm3/m;->u:Lk0/c;

    iput-object v0, p0, Lm3/m;->v:Lm3/m$c;

    return-void
.end method


# virtual methods
.method public declared-synchronized a(Lc4/g;Ljava/util/concurrent/Executor;)V
    .registers 5

    monitor-enter p0

    :try_start_1
    iget-object v0, p0, Lm3/m;->s:Lh4/d;

    invoke-virtual {v0}, Lh4/d;->a()V

    iget-object v0, p0, Lm3/m;->r:Lm3/m$e;

    .line 1
    iget-object v0, v0, Lm3/m$e;->r:Ljava/util/List;

    new-instance v1, Lm3/m$d;

    invoke-direct {v1, p1, p2}, Lm3/m$d;-><init>(Lc4/g;Ljava/util/concurrent/Executor;)V

    invoke-interface {v0, v1}, Ljava/util/List;->add(Ljava/lang/Object;)Z

    .line 2
    iget-boolean v0, p0, Lm3/m;->J:Z

    const/4 v1, 0x1

    if-eqz v0, :cond_20

    invoke-virtual {p0, v1}, Lm3/m;->e(I)V

    new-instance v0, Lm3/m$b;

    invoke-direct {v0, p0, p1}, Lm3/m$b;-><init>(Lm3/m;Lc4/g;)V

    goto :goto_2c

    :cond_20
    iget-boolean v0, p0, Lm3/m;->L:Z

    if-eqz v0, :cond_30

    invoke-virtual {p0, v1}, Lm3/m;->e(I)V

    new-instance v0, Lm3/m$a;

    invoke-direct {v0, p0, p1}, Lm3/m$a;-><init>(Lm3/m;Lc4/g;)V

    :goto_2c
    invoke-interface {p2, v0}, Ljava/util/concurrent/Executor;->execute(Ljava/lang/Runnable;)V

    goto :goto_3b

    :cond_30
    iget-boolean p1, p0, Lm3/m;->O:Z

    if-nez p1, :cond_35

    goto :goto_36

    :cond_35
    const/4 v1, 0x0

    :goto_36
    const-string p1, "Cannot add callbacks to a cancelled EngineJob"

    invoke-static {v1, p1}, Lp/e;->b(ZLjava/lang/String;)V
    :try_end_3b
    .catchall {:try_start_1 .. :try_end_3b} :catchall_3d

    :goto_3b
    monitor-exit p0

    return-void

    :catchall_3d
    move-exception p1

    monitor-exit p0

    throw p1
.end method

.method public b()V
    .registers 5

    invoke-virtual {p0}, Lm3/m;->f()Z

    move-result v0

    if-eqz v0, :cond_7

    return-void

    :cond_7
    const/4 v0, 0x1

    iput-boolean v0, p0, Lm3/m;->O:Z

    iget-object v1, p0, Lm3/m;->N:Lm3/i;

    .line 1
    iput-boolean v0, v1, Lm3/i;->V:Z

    iget-object v0, v1, Lm3/i;->T:Lm3/g;

    if-eqz v0, :cond_15

    invoke-interface {v0}, Lm3/g;->cancel()V

    .line 2
    :cond_15
    iget-object v0, p0, Lm3/m;->w:Lm3/n;

    iget-object v1, p0, Lm3/m;->C:Lk3/c;

    check-cast v0, Lm3/l;

    .line 3
    monitor-enter v0

    :try_start_1c
    iget-object v2, v0, Lm3/l;->a:Lm3/t;

    invoke-static {v2}, Ljava/util/Objects;->requireNonNull(Ljava/lang/Object;)Ljava/lang/Object;

    .line 4
    iget-boolean v3, p0, Lm3/m;->G:Z

    .line 5
    invoke-virtual {v2, v3}, Lm3/t;->e(Z)Ljava/util/Map;

    move-result-object v2

    invoke-interface {v2, v1}, Ljava/util/Map;->get(Ljava/lang/Object;)Ljava/lang/Object;

    move-result-object v3

    invoke-virtual {p0, v3}, Ljava/lang/Object;->equals(Ljava/lang/Object;)Z

    move-result v3

    if-eqz v3, :cond_34

    invoke-interface {v2, v1}, Ljava/util/Map;->remove(Ljava/lang/Object;)Ljava/lang/Object;
    :try_end_34
    .catchall {:try_start_1c .. :try_end_34} :catchall_36

    .line 6
    :cond_34
    monitor-exit v0

    return-void

    :catchall_36
    move-exception v1

    monitor-exit v0

    throw v1
.end method

.method public c()V
    .registers 4

    monitor-enter p0

    :try_start_1
    iget-object v0, p0, Lm3/m;->s:Lh4/d;

    invoke-virtual {v0}, Lh4/d;->a()V

    invoke-virtual {p0}, Lm3/m;->f()Z

    move-result v0

    const-string v1, "Not yet complete!"

    invoke-static {v0, v1}, Lp/e;->b(ZLjava/lang/String;)V

    iget-object v0, p0, Lm3/m;->B:Ljava/util/concurrent/atomic/AtomicInteger;

    invoke-virtual {v0}, Ljava/util/concurrent/atomic/AtomicInteger;->decrementAndGet()I

    move-result v0

    if-ltz v0, :cond_19

    const/4 v1, 0x1

    goto :goto_1a

    :cond_19
    const/4 v1, 0x0

    :goto_1a
    const-string v2, "Can\'t decrement below 0"

    invoke-static {v1, v2}, Lp/e;->b(ZLjava/lang/String;)V

    if-nez v0, :cond_27

    iget-object v0, p0, Lm3/m;->M:Lm3/q;

    invoke-virtual {p0}, Lm3/m;->g()V

    goto :goto_28

    :cond_27
    const/4 v0, 0x0

    :goto_28
    monitor-exit p0
    :try_end_29
    .catchall {:try_start_1 .. :try_end_29} :catchall_2f

    if-eqz v0, :cond_2e

    invoke-virtual {v0}, Lm3/q;->e()V

    :cond_2e
    return-void

    :catchall_2f
    move-exception v0

    :try_start_30
    monitor-exit p0
    :try_end_31
    .catchall {:try_start_30 .. :try_end_31} :catchall_2f

    throw v0
.end method

.method public d()Lh4/d;
    .registers 2

    iget-object v0, p0, Lm3/m;->s:Lh4/d;

    return-object v0
.end method

.method public declared-synchronized e(I)V
    .registers 4

    monitor-enter p0

    :try_start_1
    invoke-virtual {p0}, Lm3/m;->f()Z

    move-result v0

    const-string v1, "Not yet complete!"

    invoke-static {v0, v1}, Lp/e;->b(ZLjava/lang/String;)V

    iget-object v0, p0, Lm3/m;->B:Ljava/util/concurrent/atomic/AtomicInteger;

    invoke-virtual {v0, p1}, Ljava/util/concurrent/atomic/AtomicInteger;->getAndAdd(I)I

    move-result p1

    if-nez p1, :cond_19

    iget-object p1, p0, Lm3/m;->M:Lm3/q;

    if-eqz p1, :cond_19

    invoke-virtual {p1}, Lm3/q;->d()V
    :try_end_19
    .catchall {:try_start_1 .. :try_end_19} :catchall_1b

    :cond_19
    monitor-exit p0

    return-void

    :catchall_1b
    move-exception p1

    monitor-exit p0

    throw p1
.end method

.method public final f()Z
    .registers 2

    iget-boolean v0, p0, Lm3/m;->L:Z

    if-nez v0, :cond_f

    iget-boolean v0, p0, Lm3/m;->J:Z

    if-nez v0, :cond_f

    iget-boolean v0, p0, Lm3/m;->O:Z

    if-eqz v0, :cond_d

    goto :goto_f

    :cond_d
    const/4 v0, 0x0

    goto :goto_10

    :cond_f
    :goto_f
    const/4 v0, 0x1

    :goto_10
    return v0
.end method

.method public final declared-synchronized g()V
    .registers 6

    monitor-enter p0

    :try_start_1
    iget-object v0, p0, Lm3/m;->C:Lk3/c;

    if-eqz v0, :cond_3e

    iget-object v0, p0, Lm3/m;->r:Lm3/m$e;

    .line 1
    iget-object v0, v0, Lm3/m$e;->r:Ljava/util/List;

    invoke-interface {v0}, Ljava/util/List;->clear()V

    const/4 v0, 0x0

    .line 2
    iput-object v0, p0, Lm3/m;->C:Lk3/c;

    iput-object v0, p0, Lm3/m;->M:Lm3/q;

    iput-object v0, p0, Lm3/m;->H:Lm3/w;

    const/4 v1, 0x0

    iput-boolean v1, p0, Lm3/m;->L:Z

    iput-boolean v1, p0, Lm3/m;->O:Z

    iput-boolean v1, p0, Lm3/m;->J:Z

    iput-boolean v1, p0, Lm3/m;->P:Z

    iget-object v2, p0, Lm3/m;->N:Lm3/i;

    .line 3
    iget-object v3, v2, Lm3/i;->x:Lm3/i$e;

    .line 4
    monitor-enter v3
    :try_end_21
    .catchall {:try_start_1 .. :try_end_21} :catchall_44

    const/4 v4, 0x1

    :try_start_22
    iput-boolean v4, v3, Lm3/i$e;->a:Z

    invoke-virtual {v3, v1}, Lm3/i$e;->a(Z)Z

    move-result v1
    :try_end_28
    .catchall {:try_start_22 .. :try_end_28} :catchall_3b

    :try_start_28
    monitor-exit v3

    if-eqz v1, :cond_2e

    .line 5
    invoke-virtual {v2}, Lm3/i;->l()V

    .line 6
    :cond_2e
    iput-object v0, p0, Lm3/m;->N:Lm3/i;

    iput-object v0, p0, Lm3/m;->K:Lm3/r;

    iput-object v0, p0, Lm3/m;->I:Lcom/bumptech/glide/load/a;

    iget-object v0, p0, Lm3/m;->u:Lk0/c;

    invoke-interface {v0, p0}, Lk0/c;->a(Ljava/lang/Object;)Z
    :try_end_39
    .catchall {:try_start_28 .. :try_end_39} :catchall_44

    monitor-exit p0

    return-void

    :catchall_3b
    move-exception v0

    .line 7
    :try_start_3c
    monitor-exit v3

    throw v0

    .line 8
    :cond_3e
    new-instance v0, Ljava/lang/IllegalArgumentException;

    invoke-direct {v0}, Ljava/lang/IllegalArgumentException;-><init>()V

    throw v0
    :try_end_44
    .catchall {:try_start_3c .. :try_end_44} :catchall_44

    :catchall_44
    move-exception v0

    monitor-exit p0

    throw v0
.end method

.method public declared-synchronized h(Lc4/g;)V
    .registers 5

    monitor-enter p0

    :try_start_1
    iget-object v0, p0, Lm3/m;->s:Lh4/d;

    invoke-virtual {v0}, Lh4/d;->a()V

    iget-object v0, p0, Lm3/m;->r:Lm3/m$e;

    .line 1
    iget-object v0, v0, Lm3/m$e;->r:Ljava/util/List;

    .line 2
    new-instance v1, Lm3/m$d;

    sget-object v2, Lg4/e;->b:Ljava/util/concurrent/Executor;

    invoke-direct {v1, p1, v2}, Lm3/m$d;-><init>(Lc4/g;Ljava/util/concurrent/Executor;)V

    .line 3
    invoke-interface {v0, v1}, Ljava/util/List;->remove(Ljava/lang/Object;)Z

    .line 4
    iget-object p1, p0, Lm3/m;->r:Lm3/m$e;

    invoke-virtual {p1}, Lm3/m$e;->isEmpty()Z

    move-result p1

    if-eqz p1, :cond_38

    invoke-virtual {p0}, Lm3/m;->b()V

    iget-boolean p1, p0, Lm3/m;->J:Z

    if-nez p1, :cond_2a

    iget-boolean p1, p0, Lm3/m;->L:Z

    if-eqz p1, :cond_28

    goto :goto_2a

    :cond_28
    const/4 p1, 0x0

    goto :goto_2b

    :cond_2a
    :goto_2a
    const/4 p1, 0x1

    :goto_2b
    if-eqz p1, :cond_38

    iget-object p1, p0, Lm3/m;->B:Ljava/util/concurrent/atomic/AtomicInteger;

    invoke-virtual {p1}, Ljava/util/concurrent/atomic/AtomicInteger;->get()I

    move-result p1

    if-nez p1, :cond_38

    invoke-virtual {p0}, Lm3/m;->g()V
    :try_end_38
    .catchall {:try_start_1 .. :try_end_38} :catchall_3a

    :cond_38
    monitor-exit p0

    return-void

    :catchall_3a
    move-exception p1

    monitor-exit p0

    throw p1
.end method

.method public i(Lm3/i;)V
    .registers 3
    .annotation system Ldalvik/annotation/Signature;
        value = {
            "(",
            "Lm3/i<",
            "*>;)V"
        }
    .end annotation

    .line 1
    iget-boolean v0, p0, Lm3/m;->E:Z

    if-eqz v0, :cond_7

    iget-object v0, p0, Lm3/m;->z:Lp3/a;

    goto :goto_10

    :cond_7
    iget-boolean v0, p0, Lm3/m;->F:Z

    if-eqz v0, :cond_e

    iget-object v0, p0, Lm3/m;->A:Lp3/a;

    goto :goto_10

    :cond_e
    iget-object v0, p0, Lm3/m;->y:Lp3/a;

    .line 2
    :goto_10
    iget-object v0, v0, Lp3/a;->r:Ljava/util/concurrent/ExecutorService;

    invoke-interface {v0, p1}, Ljava/util/concurrent/ExecutorService;->execute(Ljava/lang/Runnable;)V

    return-void
.end method
