package a.i.b.a.c.i.e;

import a.f.a.b;
import a.f.b.j;
import a.i.b.a.c.b.ah;
import a.i.b.a.c.b.al;
import a.i.b.a.c.b.l;
import a.i.b.a.c.f.f;
import a.i.b.a.c.i.k;
import a.i.b.a.c.l.w;
import a.o;
import a.v;
import com.google.firebase.analytics.FirebaseAnalytics$b;
import com.tencent.matrix.trace.core.AppMethodBeat;
import java.util.ArrayList;
import java.util.Collection;
import java.util.List;

public final class m extends a {
    public static final a BGp = new a();
    private final b BGo;

    public static final class a {
        private a() {
        }

        public /* synthetic */ a(byte b) {
            this();
        }
    }

    static {
        AppMethodBeat.i(122228);
        AppMethodBeat.o(122228);
    }

    private m(b bVar) {
        this.BGo = bVar;
    }

    private /* synthetic */ m(b bVar, byte b) {
        this(bVar);
    }

    public final Collection<al> b(f fVar, a.i.b.a.c.c.a.a aVar) {
        AppMethodBeat.i(122225);
        j.p(fVar, "name");
        j.p(aVar, FirebaseAnalytics$b.LOCATION);
        Collection b = k.b(super.b(fVar, aVar), (b) c.BGr);
        AppMethodBeat.o(122225);
        return b;
    }

    public final Collection<ah> a(f fVar, a.i.b.a.c.c.a.a aVar) {
        AppMethodBeat.i(122226);
        j.p(fVar, "name");
        j.p(aVar, FirebaseAnalytics$b.LOCATION);
        Collection b = k.b(super.a(fVar, aVar), (b) d.BGs);
        AppMethodBeat.o(122226);
        return b;
    }

    public final Collection<l> a(d dVar, b<? super f, Boolean> bVar) {
        AppMethodBeat.i(122227);
        j.p(dVar, "kindFilter");
        j.p(bVar, "nameFilter");
        Iterable a = super.a(dVar, bVar);
        ArrayList arrayList = new ArrayList();
        ArrayList arrayList2 = new ArrayList();
        for (Object next : a) {
            if (((l) next) instanceof a.i.b.a.c.b.a) {
                arrayList.add(next);
            } else {
                arrayList2.add(next);
            }
        }
        o oVar = new o(arrayList, arrayList2);
        List list = (List) oVar.first;
        List list2 = (List) oVar.second;
        if (list == null) {
            v vVar = new v("null cannot be cast to non-null type kotlin.collections.Collection<org.jetbrains.kotlin.descriptors.CallableDescriptor>");
            AppMethodBeat.o(122227);
            throw vVar;
        }
        Collection b = a.a.j.b(k.b(list, (b) b.BGq), list2);
        AppMethodBeat.o(122227);
        return b;
    }

    public final /* bridge */ /* synthetic */ h ejA() {
        return (h) this.BGo;
    }

    public static final h a(String str, Collection<? extends w> collection) {
        AppMethodBeat.i(122229);
        j.p(str, "message");
        j.p(collection, "types");
        Iterable<w> iterable = collection;
        Collection arrayList = new ArrayList(a.a.j.d(iterable));
        for (w dXR : iterable) {
            arrayList.add(dXR.dXR());
        }
        b bVar = new b(str, (List) arrayList);
        h hVar;
        if (collection.size() <= 1) {
            hVar = (h) bVar;
            AppMethodBeat.o(122229);
            return hVar;
        }
        hVar = (h) new m(bVar, (byte) 0);
        AppMethodBeat.o(122229);
        return hVar;
    }
}
