package defpackage;

import java.util.ConcurrentModificationException;
import java.util.Iterator;

/* JADX INFO: renamed from: ᵨᵫˊ, reason: contains not printable characters */
/* JADX INFO: loaded from: classes3.dex */
public final class C3766 implements Iterator {

    /* JADX INFO: renamed from: ˌᴵ, reason: contains not printable characters */
    public int f14329;

    /* JADX INFO: renamed from: ᵔᵖᵹᵫ, reason: contains not printable characters */
    public int f14330;

    /* JADX INFO: renamed from: ᵜᵪʾ, reason: contains not printable characters */
    public int f14331;

    /* JADX INFO: renamed from: ᵨᵼⁱ, reason: contains not printable characters */
    public final /* synthetic */ C4072 f14332;

    /* JADX INFO: renamed from: ᵯᵷʽ, reason: contains not printable characters */
    public final /* synthetic */ int f14333;

    /* JADX INFO: renamed from: ᵶˇᵱ, reason: contains not printable characters */
    public final /* synthetic */ C4072 f14334;

    public C3766(C4072 c4072, int i) {
        this.f14333 = i;
        this.f14334 = c4072;
        this.f14332 = c4072;
        this.f14329 = c4072.f15648;
        this.f14331 = c4072.isEmpty() ? -1 : 0;
        this.f14330 = -1;
    }

    @Override // java.util.Iterator
    public final boolean hasNext() {
        return this.f14331 >= 0;
    }

    @Override // java.util.Iterator
    public final Object next() {
        Object c0712;
        C4072 c4072 = this.f14332;
        if (c4072.f15648 != this.f14329) {
            throw new ConcurrentModificationException();
        }
        if (!hasNext()) {
            C4468.m9518();
            return null;
        }
        int i = this.f14331;
        this.f14330 = i;
        int i2 = this.f14333;
        C4072 c40722 = this.f14334;
        switch (i2) {
            case 0:
                c0712 = c40722.m8935()[i];
                break;
            case 1:
                c0712 = new C0712(c40722, i);
                break;
            default:
                c0712 = c40722.m8937()[i];
                break;
        }
        int i3 = this.f14331 + 1;
        if (i3 >= c4072.f15649) {
            i3 = -1;
        }
        this.f14331 = i3;
        return c0712;
    }

    @Override // java.util.Iterator
    public final void remove() {
        C4072 c4072 = this.f14332;
        if (c4072.f15648 != this.f14329) {
            throw new ConcurrentModificationException();
        }
        ᵻᵪ.ˊᵨᵧ("no calls to next() since the last call to remove()", this.f14330 >= 0);
        this.f14329 += 32;
        c4072.remove(c4072.m8935()[this.f14330]);
        this.f14331--;
        this.f14330 = -1;
    }
}
