package defpackage;

/* JADX INFO: renamed from: ᵰᵞᵛᵶ, reason: contains not printable characters */
/* JADX INFO: loaded from: classes3.dex */
public final class C4382 implements InterfaceC4110, InterfaceC2653 {

    /* JADX INFO: renamed from: ʽˈˋ, reason: contains not printable characters */
    public final InterfaceC4110 f16639;

    /* JADX INFO: renamed from: ːˏᵟᵯ, reason: contains not printable characters */
    public volatile InterfaceC2653 f16640;

    /* JADX INFO: renamed from: ᵲᵶᵳˈ, reason: contains not printable characters */
    public final Object f16642;

    /* JADX INFO: renamed from: ᵷᵺʾᵖ, reason: contains not printable characters */
    public volatile InterfaceC2653 f16643;

    /* JADX INFO: renamed from: ᵨᵣ, reason: contains not printable characters */
    public int f16641 = 3;

    /* JADX INFO: renamed from: ᵻˈᵦʼ, reason: contains not printable characters */
    public int f16644 = 3;

    public C4382(Object obj, InterfaceC4110 interfaceC4110) {
        this.f16642 = obj;
        this.f16639 = interfaceC4110;
    }

    @Override // defpackage.InterfaceC2653
    public final void clear() {
        synchronized (this.f16642) {
            try {
                this.f16641 = 3;
                this.f16640.clear();
                if (this.f16644 != 3) {
                    this.f16644 = 3;
                    this.f16643.clear();
                }
            } catch (Throwable th) {
                throw th;
            }
        }
    }

    /* JADX WARN: Multi-variable type inference failed */
    /* JADX WARN: Type inference failed for: r2v2, types: [ᵭʔʾˆ] */
    /* JADX WARN: Type inference failed for: r2v4 */
    /* JADX WARN: Type inference failed for: r2v5 */
    @Override // defpackage.InterfaceC4110
    public final InterfaceC4110 getRoot() {
        ?? root;
        synchronized (this.f16642) {
            try {
                InterfaceC4110 interfaceC4110 = this.f16639;
                this = this;
                if (interfaceC4110 != null) {
                    root = interfaceC4110.getRoot();
                }
            } catch (Throwable th) {
                throw th;
            }
        }
        return root;
    }

    @Override // defpackage.InterfaceC2653
    public final boolean isRunning() {
        boolean z;
        synchronized (this.f16642) {
            try {
                z = true;
                if (this.f16641 != 1 && this.f16644 != 1) {
                    z = false;
                }
            } finally {
            }
        }
        return z;
    }

    @Override // defpackage.InterfaceC2653
    /* JADX INFO: renamed from: ʽˈˋ */
    public final boolean mo1479(InterfaceC2653 interfaceC2653) {
        if (interfaceC2653 instanceof C4382) {
            C4382 c4382 = (C4382) interfaceC2653;
            if (this.f16640.mo1479(c4382.f16640) && this.f16643.mo1479(c4382.f16643)) {
                return true;
            }
        }
        return false;
    }

    @Override // defpackage.InterfaceC4110
    /* JADX INFO: renamed from: ˊᵫᵗ */
    public final boolean mo1480(InterfaceC2653 interfaceC2653) {
        boolean z;
        synchronized (this.f16642) {
            InterfaceC4110 interfaceC4110 = this.f16639;
            z = interfaceC4110 == null || interfaceC4110.mo1480(this);
        }
        return z;
    }

    @Override // defpackage.InterfaceC4110
    /* JADX INFO: renamed from: ːˏᵟᵯ */
    public final void mo1481(InterfaceC2653 interfaceC2653) {
        synchronized (this.f16642) {
            try {
                if (interfaceC2653.equals(this.f16643)) {
                    this.f16644 = 5;
                    InterfaceC4110 interfaceC4110 = this.f16639;
                    if (interfaceC4110 != null) {
                        interfaceC4110.mo1481(this);
                    }
                    return;
                }
                this.f16641 = 5;
                if (this.f16644 != 1) {
                    this.f16644 = 1;
                    this.f16643.mo1483();
                }
            } catch (Throwable th) {
                throw th;
            }
        }
    }

    @Override // defpackage.InterfaceC2653
    /* JADX INFO: renamed from: ᵨᵣ */
    public final void mo1482() {
        synchronized (this.f16642) {
            try {
                if (this.f16641 == 1) {
                    this.f16641 = 2;
                    this.f16640.mo1482();
                }
                if (this.f16644 == 1) {
                    this.f16644 = 2;
                    this.f16643.mo1482();
                }
            } catch (Throwable th) {
                throw th;
            }
        }
    }

    @Override // defpackage.InterfaceC2653
    /* JADX INFO: renamed from: ᵱᵽʡᵚ */
    public final void mo1483() {
        synchronized (this.f16642) {
            try {
                if (this.f16641 != 1) {
                    this.f16641 = 1;
                    this.f16640.mo1483();
                }
            } catch (Throwable th) {
                throw th;
            }
        }
    }

    @Override // defpackage.InterfaceC4110, defpackage.InterfaceC2653
    /* JADX INFO: renamed from: ᵲᵶᵳˈ */
    public final boolean mo1484() {
        boolean z;
        synchronized (this.f16642) {
            try {
                z = this.f16640.mo1484() || this.f16643.mo1484();
            } finally {
            }
        }
        return z;
    }

    @Override // defpackage.InterfaceC4110
    /* JADX INFO: renamed from: ᵵᵽ */
    public final boolean mo1485(InterfaceC2653 interfaceC2653) {
        boolean z;
        int i;
        synchronized (this.f16642) {
            InterfaceC4110 interfaceC4110 = this.f16639;
            z = false;
            if (interfaceC4110 == null || interfaceC4110.mo1485(this)) {
                if (this.f16641 != 5 ? interfaceC2653.equals(this.f16640) : interfaceC2653.equals(this.f16643) && ((i = this.f16644) == 4 || i == 5)) {
                    z = true;
                }
            }
        }
        return z;
    }

    @Override // defpackage.InterfaceC2653
    /* JADX INFO: renamed from: ᵶᵥᵝ */
    public final boolean mo1486() {
        boolean z;
        synchronized (this.f16642) {
            try {
                z = this.f16641 == 4 || this.f16644 == 4;
            } finally {
            }
        }
        return z;
    }

    @Override // defpackage.InterfaceC4110
    /* JADX INFO: renamed from: ᵷᵺʾᵖ */
    public final void mo1487(InterfaceC2653 interfaceC2653) {
        synchronized (this.f16642) {
            try {
                if (interfaceC2653.equals(this.f16640)) {
                    this.f16641 = 4;
                } else if (interfaceC2653.equals(this.f16643)) {
                    this.f16644 = 4;
                }
                InterfaceC4110 interfaceC4110 = this.f16639;
                if (interfaceC4110 != null) {
                    interfaceC4110.mo1487(this);
                }
            } catch (Throwable th) {
                throw th;
            }
        }
    }

    @Override // defpackage.InterfaceC2653
    /* JADX INFO: renamed from: ᵻʽᵯ */
    public final boolean mo1488() {
        boolean z;
        synchronized (this.f16642) {
            try {
                z = this.f16641 == 3 && this.f16644 == 3;
            } finally {
            }
        }
        return z;
    }

    @Override // defpackage.InterfaceC4110
    /* JADX INFO: renamed from: ᵻˈᵦʼ */
    public final boolean mo1489(InterfaceC2653 interfaceC2653) {
        boolean z;
        synchronized (this.f16642) {
            InterfaceC4110 interfaceC4110 = this.f16639;
            z = (interfaceC4110 == null || interfaceC4110.mo1489(this)) && interfaceC2653.equals(this.f16640);
        }
        return z;
    }
}
