package p138.p176.p177.p190.p217;

import android.os.Handler;
import android.os.Looper;
import java.util.ArrayList;
import java.util.HashSet;
import java.util.Iterator;
import p000.p001.p002.p003.p004.C0567;
import p138.p176.p177.p190.AbstractC3457;
import p138.p176.p177.p190.p217.InterfaceC3800;
import p138.p176.p177.p190.p217.InterfaceC3803;
import p138.p176.p177.p190.p238.InterfaceC4115;

/* JADX INFO: renamed from: ދ.ހ.֏.ؠ.ໞ.މ, reason: contains not printable characters */
/* JADX INFO: loaded from: classes.dex */
public abstract class AbstractC3790 implements InterfaceC3800 {

    /* JADX INFO: renamed from: ރ, reason: contains not printable characters */
    public final ArrayList<InterfaceC3800.InterfaceC3802> f11609 = new ArrayList<>(1);

    /* JADX INFO: renamed from: ބ, reason: contains not printable characters */
    public final HashSet<InterfaceC3800.InterfaceC3802> f11610 = new HashSet<>(1);

    /* JADX INFO: renamed from: ޅ, reason: contains not printable characters */
    public final InterfaceC3803.C3804 f11611 = new InterfaceC3803.C3804();

    /* JADX INFO: renamed from: ކ, reason: contains not printable characters */
    public Looper f11612;

    /* JADX INFO: renamed from: އ, reason: contains not printable characters */
    public AbstractC3457 f11613;

    /* JADX INFO: renamed from: ֏, reason: contains not printable characters */
    public final InterfaceC3803.C3804 m6096(InterfaceC3800.C3801 c3801) {
        return new InterfaceC3803.C3804(this.f11611.f11636, 0, c3801, 0L);
    }

    @Override // p138.p176.p177.p190.p217.InterfaceC3800
    /* JADX INFO: renamed from: ֏, reason: contains not printable characters */
    public final void mo6097(Handler handler, InterfaceC3803 interfaceC3803) {
        InterfaceC3803.C3804 c3804 = this.f11611;
        if (c3804 == null) {
            throw null;
        }
        C0567.m1896((handler == null || interfaceC3803 == null) ? false : true);
        c3804.f11636.add(new InterfaceC3803.C3804.C3805(handler, interfaceC3803));
    }

    /* JADX INFO: renamed from: ֏, reason: contains not printable characters */
    public final void m6098(AbstractC3457 abstractC3457) {
        this.f11613 = abstractC3457;
        Iterator<InterfaceC3800.InterfaceC3802> it = this.f11609.iterator();
        while (it.hasNext()) {
            it.next().mo5539(this, abstractC3457);
        }
    }

    @Override // p138.p176.p177.p190.p217.InterfaceC3800
    /* JADX INFO: renamed from: ֏, reason: contains not printable characters */
    public final void mo6099(InterfaceC3800.InterfaceC3802 interfaceC3802) {
        this.f11609.remove(interfaceC3802);
        if (this.f11609.isEmpty()) {
            this.f11612 = null;
            this.f11613 = null;
            this.f11610.clear();
            mo1217();
            return;
        }
        boolean z = !this.f11610.isEmpty();
        this.f11610.remove(interfaceC3802);
        if (z) {
            this.f11610.isEmpty();
        }
    }

    @Override // p138.p176.p177.p190.p217.InterfaceC3800
    /* JADX INFO: renamed from: ֏, reason: contains not printable characters */
    public final void mo6100(InterfaceC3800.InterfaceC3802 interfaceC3802, InterfaceC4115 interfaceC4115) {
        Looper looperMyLooper = Looper.myLooper();
        Looper looper = this.f11612;
        C0567.m1896(looper == null || looper == looperMyLooper);
        AbstractC3457 abstractC3457 = this.f11613;
        this.f11609.add(interfaceC3802);
        Looper looper2 = this.f11612;
        if (looper2 == null) {
            this.f11612 = looperMyLooper;
            this.f11610.add(interfaceC3802);
            mo1215(interfaceC4115);
        } else if (abstractC3457 != null) {
            C0567.m1856(looper2);
            this.f11610.isEmpty();
            this.f11610.add(interfaceC3802);
            interfaceC3802.mo5539(this, abstractC3457);
        }
    }

    @Override // p138.p176.p177.p190.p217.InterfaceC3800
    /* JADX INFO: renamed from: ֏, reason: contains not printable characters */
    public final void mo6101(InterfaceC3803 interfaceC3803) {
        InterfaceC3803.C3804 c3804 = this.f11611;
        for (InterfaceC3803.C3804.C3805 c3805 : c3804.f11636) {
            if (c3805.f11639 == interfaceC3803) {
                c3804.f11636.remove(c3805);
            }
        }
    }

    /* JADX INFO: renamed from: ֏ */
    public abstract void mo1215(InterfaceC4115 interfaceC4115);

    /* JADX INFO: renamed from: ؠ */
    public abstract void mo1217();
}
