.class public Ls9/q;
.super Ljava/lang/Object;
.source ""


# annotations
.annotation system Ldalvik/annotation/Signature;
    value = {
        "<T::",
        "Ls9/r;",
        ":",
        "Ljava/lang/Comparable<",
        "-TT;>;>",
        "Ljava/lang/Object;"
    }
.end annotation


# instance fields
.field private volatile synthetic _size:I

.field public a:[Ls9/r;
    .annotation system Ldalvik/annotation/Signature;
        value = {
            "[TT;"
        }
    .end annotation
.end field


# direct methods
.method public constructor <init>()V
    .registers 2

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

    const/4 v0, 0x0

    iput v0, p0, Ls9/q;->_size:I

    return-void
.end method


# virtual methods
.method public final a(Ls9/r;)V
    .registers 6
    .annotation system Ldalvik/annotation/Signature;
        value = {
            "(TT;)V"
        }
    .end annotation

    move-object v0, p1

    check-cast v0, Lq9/j0$b;

    invoke-virtual {v0, p0}, Lq9/j0$b;->b(Ls9/q;)V

    .line 1
    iget-object v1, p0, Ls9/q;->a:[Ls9/r;

    if-nez v1, :cond_10

    const/4 v1, 0x4

    new-array v1, v1, [Ls9/r;

    iput-object v1, p0, Ls9/q;->a:[Ls9/r;

    goto :goto_26

    .line 2
    :cond_10
    iget v2, p0, Ls9/q;->_size:I

    .line 3
    array-length v3, v1

    if-lt v2, v3, :cond_26

    .line 4
    iget v2, p0, Ls9/q;->_size:I

    mul-int/lit8 v2, v2, 0x2

    .line 5
    invoke-static {v1, v2}, Ljava/util/Arrays;->copyOf([Ljava/lang/Object;I)[Ljava/lang/Object;

    move-result-object v1

    const-string v2, "java.util.Arrays.copyOf(this, newSize)"

    invoke-static {v1, v2}, Lx/e;->e(Ljava/lang/Object;Ljava/lang/String;)V

    check-cast v1, [Ls9/r;

    iput-object v1, p0, Ls9/q;->a:[Ls9/r;

    .line 6
    :cond_26
    :goto_26
    iget v2, p0, Ls9/q;->_size:I

    add-int/lit8 v3, v2, 0x1

    .line 7
    iput v3, p0, Ls9/q;->_size:I

    .line 8
    aput-object p1, v1, v2

    .line 9
    iput v2, v0, Lq9/j0$b;->t:I

    .line 10
    invoke-virtual {p0, v2}, Ls9/q;->f(I)V

    return-void
.end method

.method public final b()Ls9/r;
    .registers 3
    .annotation system Ldalvik/annotation/Signature;
        value = {
            "()TT;"
        }
    .end annotation

    iget-object v0, p0, Ls9/q;->a:[Ls9/r;

    if-nez v0, :cond_6

    const/4 v0, 0x0

    goto :goto_9

    :cond_6
    const/4 v1, 0x0

    aget-object v0, v0, v1

    :goto_9
    return-object v0
.end method

.method public final c()Z
    .registers 2

    .line 1
    iget v0, p0, Ls9/q;->_size:I

    if-nez v0, :cond_6

    const/4 v0, 0x1

    goto :goto_7

    :cond_6
    const/4 v0, 0x0

    :goto_7
    return v0
.end method

.method public final d(I)Ls9/r;
    .registers 9
    .annotation system Ldalvik/annotation/Signature;
        value = {
            "(I)TT;"
        }
    .end annotation

    iget-object v0, p0, Ls9/q;->a:[Ls9/r;

    invoke-static {v0}, Lx/e;->d(Ljava/lang/Object;)V

    .line 1
    iget v1, p0, Ls9/q;->_size:I

    const/4 v2, -0x1

    add-int/2addr v1, v2

    .line 2
    iput v1, p0, Ls9/q;->_size:I

    .line 3
    iget v1, p0, Ls9/q;->_size:I

    if-ge p1, v1, :cond_72

    iget v1, p0, Ls9/q;->_size:I

    .line 4
    invoke-virtual {p0, p1, v1}, Ls9/q;->g(II)V

    add-int/lit8 v1, p1, -0x1

    div-int/lit8 v1, v1, 0x2

    if-lez p1, :cond_33

    aget-object v3, v0, p1

    invoke-static {v3}, Lx/e;->d(Ljava/lang/Object;)V

    check-cast v3, Ljava/lang/Comparable;

    aget-object v4, v0, v1

    invoke-static {v4}, Lx/e;->d(Ljava/lang/Object;)V

    invoke-interface {v3, v4}, Ljava/lang/Comparable;->compareTo(Ljava/lang/Object;)I

    move-result v3

    if-gez v3, :cond_33

    invoke-virtual {p0, p1, v1}, Ls9/q;->g(II)V

    invoke-virtual {p0, v1}, Ls9/q;->f(I)V

    goto :goto_72

    :cond_33
    :goto_33
    mul-int/lit8 v1, p1, 0x2

    add-int/lit8 v1, v1, 0x1

    .line 5
    iget v3, p0, Ls9/q;->_size:I

    if-lt v1, v3, :cond_3c

    goto :goto_72

    .line 6
    :cond_3c
    iget-object v3, p0, Ls9/q;->a:[Ls9/r;

    invoke-static {v3}, Lx/e;->d(Ljava/lang/Object;)V

    add-int/lit8 v4, v1, 0x1

    .line 7
    iget v5, p0, Ls9/q;->_size:I

    if-ge v4, v5, :cond_5a

    .line 8
    aget-object v5, v3, v4

    invoke-static {v5}, Lx/e;->d(Ljava/lang/Object;)V

    check-cast v5, Ljava/lang/Comparable;

    aget-object v6, v3, v1

    invoke-static {v6}, Lx/e;->d(Ljava/lang/Object;)V

    invoke-interface {v5, v6}, Ljava/lang/Comparable;->compareTo(Ljava/lang/Object;)I

    move-result v5

    if-gez v5, :cond_5a

    move v1, v4

    :cond_5a
    aget-object v4, v3, p1

    invoke-static {v4}, Lx/e;->d(Ljava/lang/Object;)V

    check-cast v4, Ljava/lang/Comparable;

    aget-object v3, v3, v1

    invoke-static {v3}, Lx/e;->d(Ljava/lang/Object;)V

    invoke-interface {v4, v3}, Ljava/lang/Comparable;->compareTo(Ljava/lang/Object;)I

    move-result v3

    if-gtz v3, :cond_6d

    goto :goto_72

    :cond_6d
    invoke-virtual {p0, p1, v1}, Ls9/q;->g(II)V

    move p1, v1

    goto :goto_33

    .line 9
    :cond_72
    :goto_72
    iget p1, p0, Ls9/q;->_size:I

    .line 10
    aget-object p1, v0, p1

    invoke-static {p1}, Lx/e;->d(Ljava/lang/Object;)V

    const/4 v1, 0x0

    invoke-interface {p1, v1}, Ls9/r;->b(Ls9/q;)V

    invoke-interface {p1, v2}, Ls9/r;->a(I)V

    .line 11
    iget v2, p0, Ls9/q;->_size:I

    .line 12
    aput-object v1, v0, v2

    return-object p1
.end method

.method public final e()Ls9/r;
    .registers 2
    .annotation system Ldalvik/annotation/Signature;
        value = {
            "()TT;"
        }
    .end annotation

    monitor-enter p0

    .line 1
    :try_start_1
    iget v0, p0, Ls9/q;->_size:I

    if-lez v0, :cond_b

    const/4 v0, 0x0

    .line 2
    invoke-virtual {p0, v0}, Ls9/q;->d(I)Ls9/r;

    move-result-object v0
    :try_end_a
    .catchall {:try_start_1 .. :try_end_a} :catchall_e

    goto :goto_c

    :cond_b
    const/4 v0, 0x0

    :goto_c
    monitor-exit p0

    return-object v0

    :catchall_e
    move-exception v0

    monitor-exit p0

    throw v0
.end method

.method public final f(I)V
    .registers 5

    :goto_0
    if-gtz p1, :cond_3

    return-void

    :cond_3
    iget-object v0, p0, Ls9/q;->a:[Ls9/r;

    invoke-static {v0}, Lx/e;->d(Ljava/lang/Object;)V

    add-int/lit8 v1, p1, -0x1

    div-int/lit8 v1, v1, 0x2

    aget-object v2, v0, v1

    invoke-static {v2}, Lx/e;->d(Ljava/lang/Object;)V

    check-cast v2, Ljava/lang/Comparable;

    aget-object v0, v0, p1

    invoke-static {v0}, Lx/e;->d(Ljava/lang/Object;)V

    invoke-interface {v2, v0}, Ljava/lang/Comparable;->compareTo(Ljava/lang/Object;)I

    move-result v0

    if-gtz v0, :cond_1f

    return-void

    :cond_1f
    invoke-virtual {p0, p1, v1}, Ls9/q;->g(II)V

    move p1, v1

    goto :goto_0
.end method

.method public final g(II)V
    .registers 6

    iget-object v0, p0, Ls9/q;->a:[Ls9/r;

    invoke-static {v0}, Lx/e;->d(Ljava/lang/Object;)V

    aget-object v1, v0, p2

    invoke-static {v1}, Lx/e;->d(Ljava/lang/Object;)V

    aget-object v2, v0, p1

    invoke-static {v2}, Lx/e;->d(Ljava/lang/Object;)V

    aput-object v1, v0, p1

    aput-object v2, v0, p2

    invoke-interface {v1, p1}, Ls9/r;->a(I)V

    invoke-interface {v2, p2}, Ls9/r;->a(I)V

    return-void
.end method
