package com.google.gson.internal;

import com.bytedance.covode.number.Covode;
import com.google.gson.a;
import com.google.gson.a.d;
import com.google.gson.a.e;
import com.google.gson.v;
import java.util.ArrayList;
import java.util.Collections;
import java.util.List;

public final class Excluder implements v, Cloneable {
    public static final Excluder LIZ = new Excluder();
    public double LIZIZ = -1.0d;
    public int LIZJ = 136;
    public boolean LIZLLL = true;
    public boolean LJ;
    public List<a> LJFF = Collections.emptyList();
    public List<a> LJI = Collections.emptyList();

    static {
        Covode.recordClassIndex(45394);
    }

    /* renamed from: LIZ */
    public final Excluder clone() {
        try {
            return (Excluder) super.clone();
        } catch (CloneNotSupportedException e) {
            throw new AssertionError(e);
        }
    }

    private boolean LIZ(d dVar) {
        if (dVar == null || dVar.LIZ() <= this.LIZIZ) {
            return true;
        }
        return false;
    }

    private boolean LIZLLL(Class<?> cls) {
        if ((cls.getModifiers() & 8) != 0) {
            return true;
        }
        return false;
    }

    public final boolean LIZJ(Class<?> cls) {
        if (!cls.isMemberClass() || LIZLLL(cls)) {
            return false;
        }
        return true;
    }

    private boolean LIZ(e eVar) {
        if (eVar == null || eVar.LIZ() > this.LIZIZ) {
            return true;
        }
        return false;
    }

    public final boolean LIZIZ(Class<?> cls) {
        if (Enum.class.isAssignableFrom(cls)) {
            return false;
        }
        if (cls.isAnonymousClass() || cls.isLocalClass()) {
            return true;
        }
        return false;
    }

    public final boolean LIZ(Class<?> cls) {
        if (this.LIZIZ != -1.0d && !LIZ((d) cls.getAnnotation(d.class), (e) cls.getAnnotation(e.class))) {
            return true;
        }
        if ((this.LIZLLL || !LIZJ(cls)) && !LIZIZ(cls)) {
            return false;
        }
        return true;
    }

    /* JADX WARNING: Code restructure failed: missing block: B:5:0x0012, code lost:
        if (r2 == false) goto L_0x0014;
     */
    /* Code decompiled incorrectly, please refer to instructions dump. */
    public final <T> com.google.gson.u<T> create(com.google.gson.Gson r8, com.google.gson.b.a<T> r9) {
        /*
            r7 = this;
            r6 = r9
            java.lang.Class<? super T> r3 = r6.rawType
            boolean r2 = r7.LIZ((java.lang.Class<?>) r3)
            r1 = 0
            r0 = 1
            if (r2 != 0) goto L_0x0011
            boolean r0 = r7.LIZ((java.lang.Class<?>) r3, (boolean) r0)
            if (r0 == 0) goto L_0x0023
        L_0x0011:
            r4 = 1
            if (r2 != 0) goto L_0x001a
        L_0x0014:
            boolean r0 = r7.LIZ((java.lang.Class<?>) r3, (boolean) r1)
            if (r0 == 0) goto L_0x0021
        L_0x001a:
            r3 = 1
        L_0x001b:
            if (r4 != 0) goto L_0x0025
            if (r3 != 0) goto L_0x0025
            r0 = 0
            return r0
        L_0x0021:
            r3 = 0
            goto L_0x001b
        L_0x0023:
            r4 = 0
            goto L_0x0014
        L_0x0025:
            com.google.gson.internal.Excluder$1 r1 = new com.google.gson.internal.Excluder$1
            r2 = r7
            r5 = r8
            r1.<init>(r3, r4, r5, r6)
            return r1
        */
        throw new UnsupportedOperationException("Method not decompiled: com.google.gson.internal.Excluder.create(com.google.gson.Gson, com.google.gson.b.a):com.google.gson.u");
    }

    public final boolean LIZ(d dVar, e eVar) {
        if (!LIZ(dVar) || !LIZ(eVar)) {
            return false;
        }
        return true;
    }

    public final boolean LIZ(Class<?> cls, boolean z) {
        List<a> list;
        if (z) {
            list = this.LJFF;
        } else {
            list = this.LJI;
        }
        for (a shouldSkipClass : list) {
            if (shouldSkipClass.shouldSkipClass(cls)) {
                return true;
            }
        }
        return false;
    }

    public final Excluder LIZ(a aVar, boolean z, boolean z2) {
        Excluder LIZ2 = clone();
        if (z) {
            ArrayList arrayList = new ArrayList(this.LJFF);
            LIZ2.LJFF = arrayList;
            arrayList.add(aVar);
        }
        if (z2) {
            ArrayList arrayList2 = new ArrayList(this.LJI);
            LIZ2.LJI = arrayList2;
            arrayList2.add(aVar);
        }
        return LIZ2;
    }
}
