package p138.p176.p177.p190.p198.p205;

import java.util.Arrays;
import p000.p001.p002.p003.p004.C0567;
import p138.p176.p177.p190.p198.C3558;
import p138.p176.p177.p190.p198.C3564;
import p138.p176.p177.p190.p198.C3566;
import p138.p176.p177.p190.p198.InterfaceC3571;
import p138.p176.p177.p190.p198.p205.AbstractC3644;
import p138.p176.p177.p190.p210.C3710;
import p138.p176.p177.p190.p239.C4128;
import p138.p176.p177.p190.p239.C4140;
import p138.p176.p177.p190.p239.C4150;

/* JADX INFO: renamed from: ދ.ހ.֏.ؠ.ೲ.ޛ.ؠ, reason: contains not printable characters */
/* JADX INFO: loaded from: classes.dex */
public final class C3637 extends AbstractC3644 {

    /* JADX INFO: renamed from: ދ, reason: contains not printable characters */
    public C4128 f11006;

    /* JADX INFO: renamed from: ތ, reason: contains not printable characters */
    public C3638 f11007;

    /* JADX INFO: renamed from: ދ.ހ.֏.ؠ.ೲ.ޛ.ؠ$֏, reason: contains not printable characters */
    public class C3638 implements InterfaceC3642 {

        /* JADX INFO: renamed from: ֏, reason: contains not printable characters */
        public long f11008 = -1;

        /* JADX INFO: renamed from: ؠ, reason: contains not printable characters */
        public long f11009 = -1;

        public C3638() {
        }

        @Override // p138.p176.p177.p190.p198.p205.InterfaceC3642
        /* JADX INFO: renamed from: ֏ */
        public long mo5982(C3558 c3558) {
            long j = this.f11009;
            if (j < 0) {
                return -1L;
            }
            long j2 = -(j + 2);
            this.f11009 = -1L;
            return j2;
        }

        @Override // p138.p176.p177.p190.p198.p205.InterfaceC3642
        /* JADX INFO: renamed from: ֏ */
        public InterfaceC3571 mo5983() {
            C0567.m1932(this.f11008 != -1);
            return new C3566(C3637.this.f11006, this.f11008);
        }

        @Override // p138.p176.p177.p190.p198.p205.InterfaceC3642
        /* JADX INFO: renamed from: ֏ */
        public void mo5984(long j) {
            C0567.m1856(C3637.this.f11006.f13190);
            long[] jArr = C3637.this.f11006.f13190.f13192;
            this.f11009 = jArr[C4150.m6787(jArr, j, true, true)];
        }
    }

    @Override // p138.p176.p177.p190.p198.p205.AbstractC3644
    /* JADX INFO: renamed from: ֏, reason: contains not printable characters */
    public long mo5986(C4140 c4140) {
        if (!(c4140.f13227[0] == -1)) {
            return -1L;
        }
        int i = (c4140.f13227[2] & 255) >> 4;
        if (i == 6 || i == 7) {
            c4140.m6695(4);
            c4140.m6708();
        }
        int iM5894 = C3564.m5894(c4140, i);
        c4140.m6693(0);
        return iM5894;
    }

    @Override // p138.p176.p177.p190.p198.p205.AbstractC3644
    /* JADX INFO: renamed from: ֏, reason: contains not printable characters */
    public void mo5987(boolean z) {
        super.mo5987(z);
        if (z) {
            this.f11006 = null;
            this.f11007 = null;
        }
    }

    @Override // p138.p176.p177.p190.p198.p205.AbstractC3644
    /* JADX INFO: renamed from: ֏, reason: contains not printable characters */
    public boolean mo5988(C4140 c4140, long j, AbstractC3644.C3646 c3646) {
        byte[] bArr = c4140.f13227;
        if (this.f11006 == null) {
            this.f11006 = new C4128(bArr, 17);
            c3646.f11042 = this.f11006.m6640(Arrays.copyOfRange(bArr, 9, c4140.f13229), (C3710) null);
        } else if ((bArr[0] & 127) == 3) {
            this.f11007 = new C3638();
            this.f11006 = this.f11006.m6642(C0567.m1930(c4140));
        } else {
            if (bArr[0] == -1) {
                C3638 c3638 = this.f11007;
                if (c3638 != null) {
                    c3638.f11008 = j;
                    c3646.f11043 = c3638;
                }
                return false;
            }
        }
        return true;
    }
}
