package p138.p176.p291.p296.p297.p301.p302;

import android.util.Base64;
import android.util.JsonReader;
import java.io.IOException;
import java.io.StringReader;
import java.io.StringWriter;
import java.util.ArrayList;
import p138.p139.p143.p144.C2803;
import p138.p176.p291.p296.p297.p301.AbstractC5781;
import p138.p176.p291.p296.p297.p301.C5713;
import p138.p176.p291.p296.p297.p301.C5734;
import p138.p176.p291.p296.p297.p301.C5737;
import p138.p176.p291.p296.p297.p301.C5739;
import p138.p176.p291.p296.p297.p301.C5741;
import p138.p176.p291.p296.p297.p301.C5743;
import p138.p176.p291.p296.p297.p301.C5746;
import p138.p176.p291.p296.p297.p301.C5749;
import p138.p176.p291.p296.p297.p301.C5752;
import p138.p176.p291.p296.p297.p301.C5755;
import p138.p176.p291.p296.p297.p301.C5757;
import p138.p176.p291.p296.p297.p301.C5760;
import p138.p176.p291.p296.p297.p301.C5762;
import p138.p176.p291.p296.p297.p301.C5764;
import p138.p176.p291.p296.p297.p301.C5766;
import p138.p176.p291.p296.p297.p301.C5768;
import p138.p176.p291.p296.p297.p301.C5771;
import p138.p176.p291.p296.p297.p301.C5774;
import p138.p176.p291.p296.p297.p301.C5776;
import p138.p176.p291.p296.p297.p301.C5779;
import p138.p176.p291.p296.p297.p301.C5810;
import p138.p176.p291.p315.InterfaceC5881;
import p138.p176.p291.p315.p317.C5892;
import p138.p176.p291.p315.p317.C5893;

/* JADX INFO: renamed from: ދ.ހ.ށ.ބ.ށ.މ.ޕ.ރ, reason: contains not printable characters */
/* JADX INFO: loaded from: classes.dex */
public class C5816 {

    /* JADX INFO: renamed from: ֏, reason: contains not printable characters */
    public static final InterfaceC5881 f16497;

    /* JADX INFO: renamed from: ދ.ހ.ށ.ބ.ށ.މ.ޕ.ރ$֏, reason: contains not printable characters */
    public interface InterfaceC5817<T> {
        /* JADX INFO: renamed from: ֏ */
        T mo9110(JsonReader jsonReader);
    }

    static {
        C5893 c5893 = new C5893();
        ((C5713) C5713.f16329).m9095(c5893);
        c5893.f16652 = true;
        f16497 = new C5892(c5893);
    }

    /* JADX INFO: renamed from: ֏, reason: contains not printable characters */
    public static /* synthetic */ AbstractC5781.AbstractC5784.AbstractC5785 m9111(JsonReader jsonReader) throws IOException {
        jsonReader.beginObject();
        C5741.C5742 c5742 = null;
        String strNextString = null;
        byte[] bArrDecode = null;
        while (jsonReader.hasNext()) {
            String strNextName = jsonReader.nextName();
            byte b = -1;
            int iHashCode = strNextName.hashCode();
            if (iHashCode != -734768633) {
                if (iHashCode == -567321830 && strNextName.equals("contents")) {
                    b = 1;
                }
            } else if (strNextName.equals("filename")) {
                b = 0;
            }
            if (b == 0) {
                strNextString = jsonReader.nextString();
                if (strNextString == null) {
                    throw new NullPointerException("Null filename");
                }
            } else if (b != 1) {
                jsonReader.skipValue();
            } else {
                bArrDecode = Base64.decode(jsonReader.nextString(), 2);
                if (bArrDecode == null) {
                    throw new NullPointerException("Null contents");
                }
            }
        }
        jsonReader.endObject();
        String strM4879 = strNextString == null ? " filename" : "";
        if (bArrDecode == null) {
            strM4879 = C2803.m4879(strM4879, " contents");
        }
        if (strM4879.isEmpty()) {
            return new C5741(strNextString, bArrDecode, c5742);
        }
        throw new IllegalStateException(C2803.m4879("Missing required properties:", strM4879));
    }

    /* JADX INFO: renamed from: ֏, reason: contains not printable characters */
    public static <T> C5810<T> m9112(JsonReader jsonReader, InterfaceC5817<T> interfaceC5817) throws IOException {
        ArrayList arrayList = new ArrayList();
        jsonReader.beginArray();
        while (jsonReader.hasNext()) {
            arrayList.add(interfaceC5817.mo9110(jsonReader));
        }
        jsonReader.endArray();
        return new C5810<>(arrayList);
    }

    /* JADX INFO: renamed from: ֏, reason: contains not printable characters */
    public static /* synthetic */ void m9113(Throwable th, AutoCloseable autoCloseable) throws Exception {
        if (th == null) {
            autoCloseable.close();
        } else {
            try {
                autoCloseable.close();
            } catch (Throwable unused) {
            }
        }
    }

    /* JADX INFO: renamed from: ؠ, reason: contains not printable characters */
    public static /* synthetic */ AbstractC5781.AbstractC5783 m9114(JsonReader jsonReader) throws IOException {
        jsonReader.beginObject();
        C5737.C5738 c5738 = null;
        String strNextString = null;
        String strNextString2 = null;
        while (jsonReader.hasNext()) {
            String strNextName = jsonReader.nextName();
            byte b = -1;
            int iHashCode = strNextName.hashCode();
            if (iHashCode != 106079) {
                if (iHashCode == 111972721 && strNextName.equals("value")) {
                    b = 1;
                }
            } else if (strNextName.equals("key")) {
                b = 0;
            }
            if (b == 0) {
                strNextString = jsonReader.nextString();
                if (strNextString == null) {
                    throw new NullPointerException("Null key");
                }
            } else if (b != 1) {
                jsonReader.skipValue();
            } else {
                strNextString2 = jsonReader.nextString();
                if (strNextString2 == null) {
                    throw new NullPointerException("Null value");
                }
            }
        }
        jsonReader.endObject();
        String strM4879 = strNextString == null ? " key" : "";
        if (strNextString2 == null) {
            strM4879 = C2803.m4879(strM4879, " value");
        }
        if (strM4879.isEmpty()) {
            return new C5737(strNextString, strNextString2, c5738);
        }
        throw new IllegalStateException(C2803.m4879("Missing required properties:", strM4879));
    }

    /* JADX INFO: renamed from: ހ, reason: contains not printable characters */
    public static /* synthetic */ AbstractC5781.AbstractC5786.AbstractC5792.AbstractC5793.AbstractC5794.AbstractC5799 m9115(JsonReader jsonReader) throws IOException {
        jsonReader.beginObject();
        C5766.C5767 c5767 = null;
        String strNextString = null;
        Integer numValueOf = null;
        C5810 c5810M9112 = null;
        while (jsonReader.hasNext()) {
            String strNextName = jsonReader.nextName();
            byte b = -1;
            int iHashCode = strNextName.hashCode();
            if (iHashCode != -1266514778) {
                if (iHashCode != 3373707) {
                    if (iHashCode == 2125650548 && strNextName.equals("importance")) {
                        b = 0;
                    }
                } else if (strNextName.equals("name")) {
                    b = 1;
                }
            } else if (strNextName.equals("frames")) {
                b = 2;
            }
            if (b == 0) {
                numValueOf = Integer.valueOf(jsonReader.nextInt());
            } else if (b == 1) {
                strNextString = jsonReader.nextString();
                if (strNextString == null) {
                    throw new NullPointerException("Null name");
                }
            } else if (b != 2) {
                jsonReader.skipValue();
            } else {
                c5810M9112 = m9112(jsonReader, new InterfaceC5817() { // from class: ދ.ހ.ށ.ބ.ށ.މ.ޕ.ނ
                    @Override // p138.p176.p291.p296.p297.p301.p302.C5816.InterfaceC5817
                    /* JADX INFO: renamed from: ֏ */
                    public Object mo9110(JsonReader jsonReader2) {
                        return C5816.m9119(jsonReader2);
                    }
                });
                if (c5810M9112 == null) {
                    throw new NullPointerException("Null frames");
                }
            }
        }
        jsonReader.endObject();
        String strM4879 = strNextString == null ? " name" : "";
        if (numValueOf == null) {
            strM4879 = C2803.m4879(strM4879, " importance");
        }
        if (c5810M9112 == null) {
            strM4879 = C2803.m4879(strM4879, " frames");
        }
        if (strM4879.isEmpty()) {
            return new C5766(strNextString, numValueOf.intValue(), c5810M9112, c5767);
        }
        throw new IllegalStateException(C2803.m4879("Missing required properties:", strM4879));
    }

    /* JADX WARN: Failed to restore switch over string. Please report as a decompilation issue */
    /* JADX INFO: renamed from: ށ, reason: contains not printable characters */
    public static /* synthetic */ AbstractC5781.AbstractC5786.AbstractC5792.AbstractC5793.AbstractC5794.AbstractC5795 m9116(JsonReader jsonReader) throws IOException {
        jsonReader.beginObject();
        Long lValueOf = null;
        Long lValueOf2 = null;
        String strNextString = null;
        String str = null;
        while (jsonReader.hasNext()) {
            String strNextName = jsonReader.nextName();
            byte b = -1;
            switch (strNextName.hashCode()) {
                case 3373707:
                    if (strNextName.equals("name")) {
                        b = 0;
                    }
                    break;
                case 3530753:
                    if (strNextName.equals("size")) {
                        b = 2;
                    }
                    break;
                case 3601339:
                    if (strNextName.equals("uuid")) {
                        b = 3;
                    }
                    break;
                case 1153765347:
                    if (strNextName.equals("baseAddress")) {
                        b = 1;
                    }
                    break;
            }
            if (b == 0) {
                strNextString = jsonReader.nextString();
                if (strNextString == null) {
                    throw new NullPointerException("Null name");
                }
            } else if (b == 1) {
                lValueOf = Long.valueOf(jsonReader.nextLong());
            } else if (b == 2) {
                lValueOf2 = Long.valueOf(jsonReader.nextLong());
            } else if (b != 3) {
                jsonReader.skipValue();
            } else {
                str = new String(Base64.decode(jsonReader.nextString(), 2), AbstractC5781.f16486);
            }
        }
        jsonReader.endObject();
        String strM4879 = lValueOf == null ? " baseAddress" : "";
        if (lValueOf2 == null) {
            strM4879 = C2803.m4879(strM4879, " size");
        }
        if (strNextString == null) {
            strM4879 = C2803.m4879(strM4879, " name");
        }
        if (strM4879.isEmpty()) {
            return new C5760(lValueOf.longValue(), lValueOf2.longValue(), strNextString, str, null);
        }
        throw new IllegalStateException(C2803.m4879("Missing required properties:", strM4879));
    }

    /* JADX WARN: Can't fix incorrect switch cases order, some code will duplicate */
    /* JADX WARN: Failed to restore switch over string. Please report as a decompilation issue */
    /* JADX WARN: Multi-variable type inference failed */
    /* JADX WARN: Removed duplicated region for block: B:113:0x01b8  */
    /* JADX WARN: Removed duplicated region for block: B:138:0x020e  */
    /* JADX WARN: Removed duplicated region for block: B:164:0x0266  */
    /* JADX WARN: Removed duplicated region for block: B:23:0x0052  */
    /* JADX WARN: Removed duplicated region for block: B:80:0x0115  */
    /* JADX WARN: Type inference failed for: r12v24 */
    /* JADX WARN: Type inference failed for: r14v3 */
    /* JADX WARN: Type inference failed for: r15v2 */
    /* JADX INFO: renamed from: ނ, reason: contains not printable characters */
    /*
        Code decompiled incorrectly, please refer to instructions dump.
    */
    public static AbstractC5781.AbstractC5786.AbstractC5792 m9117(JsonReader jsonReader) throws IOException {
        byte b;
        String strM4879;
        byte b2;
        byte b3;
        byte b4;
        byte b5;
        C5752.C5754 c5754 = new C5752.C5754();
        jsonReader.beginObject();
        while (jsonReader.hasNext()) {
            String strNextName = jsonReader.nextName();
            char c = 3;
            switch (strNextName.hashCode()) {
                case -1335157162:
                    b = !strNextName.equals("device") ? (byte) -1 : (byte) 3;
                    break;
                case 96801:
                    if (strNextName.equals("app")) {
                        b = 2;
                        break;
                    }
                    break;
                case 107332:
                    if (strNextName.equals("log")) {
                        b = 4;
                        break;
                    }
                    break;
                case 3575610:
                    if (strNextName.equals("type")) {
                        b = 1;
                        break;
                    }
                    break;
                case 55126294:
                    if (strNextName.equals("timestamp")) {
                        b = 0;
                        break;
                    }
                    break;
            }
            if (b == 0) {
                c5754.f16422 = Long.valueOf(jsonReader.nextLong());
            } else if (b != 1) {
                C5774.C5775 c5775 = null;
                if (b == 2) {
                    jsonReader.beginObject();
                    C5810 c5810M9112 = null;
                    AbstractC5781.AbstractC5786.AbstractC5792.AbstractC5793.AbstractC5794 abstractC5794Mo9103 = null;
                    Boolean boolValueOf = null;
                    Integer numValueOf = null;
                    while (jsonReader.hasNext()) {
                        String strNextName2 = jsonReader.nextName();
                        switch (strNextName2.hashCode()) {
                            case -1332194002:
                                b3 = !strNextName2.equals("background") ? (byte) -1 : (byte) 0;
                                break;
                            case -1090974952:
                                if (strNextName2.equals("execution")) {
                                    b3 = 2;
                                    break;
                                }
                                break;
                            case 555169704:
                                if (strNextName2.equals("customAttributes")) {
                                    b3 = 3;
                                    break;
                                }
                                break;
                            case 928737948:
                                if (strNextName2.equals("uiOrientation")) {
                                    b3 = 1;
                                    break;
                                }
                                break;
                        }
                        if (b3 == 0) {
                            boolValueOf = Boolean.valueOf(jsonReader.nextBoolean());
                        } else if (b3 == 1) {
                            numValueOf = Integer.valueOf(jsonReader.nextInt());
                        } else if (b3 == 2) {
                            C5757.C5759 c5759 = new C5757.C5759();
                            jsonReader.beginObject();
                            while (jsonReader.hasNext()) {
                                String strNextName3 = jsonReader.nextName();
                                switch (strNextName3.hashCode()) {
                                    case -1337936983:
                                        b4 = !strNextName3.equals("threads") ? (byte) -1 : (byte) 0;
                                        break;
                                    case -902467928:
                                        if (strNextName3.equals("signal")) {
                                            b4 = 2;
                                            break;
                                        }
                                        break;
                                    case 937615455:
                                        if (strNextName3.equals("binaries")) {
                                            b4 = 3;
                                            break;
                                        }
                                        break;
                                    case 1481625679:
                                        if (strNextName3.equals("exception")) {
                                            b4 = 1;
                                            break;
                                        }
                                        break;
                                }
                                if (b4 == 0) {
                                    c5759.f16435 = m9112(jsonReader, new InterfaceC5817() { // from class: ދ.ހ.ށ.ބ.ށ.މ.ޕ.ؠ
                                        @Override // p138.p176.p291.p296.p297.p301.p302.C5816.InterfaceC5817
                                        /* JADX INFO: renamed from: ֏ */
                                        public Object mo9110(JsonReader jsonReader2) {
                                            return C5816.m9115(jsonReader2);
                                        }
                                    });
                                } else if (b4 == 1) {
                                    c5759.f16436 = m9118(jsonReader);
                                } else if (b4 == 2) {
                                    jsonReader.beginObject();
                                    C5774.C5775 c57752 = c5775;
                                    C5774.C5775 c57753 = c57752;
                                    String strNextString = c57753;
                                    Long lValueOf = c57752;
                                    String strNextString2 = c57753;
                                    while (jsonReader.hasNext()) {
                                        String strNextName4 = jsonReader.nextName();
                                        int iHashCode = strNextName4.hashCode();
                                        if (iHashCode != -1147692044) {
                                            if (iHashCode != 3059181) {
                                                b5 = (iHashCode == 3373707 && strNextName4.equals("name")) ? (byte) 0 : (byte) -1;
                                            } else if (strNextName4.equals("code")) {
                                                b5 = 1;
                                            }
                                        } else if (strNextName4.equals("address")) {
                                            b5 = 2;
                                        }
                                        if (b5 == 0) {
                                            strNextString2 = jsonReader.nextString();
                                            if (strNextString2 == 0) {
                                                throw new NullPointerException("Null name");
                                            }
                                        } else if (b5 == 1) {
                                            strNextString = jsonReader.nextString();
                                            if (strNextString == 0) {
                                                throw new NullPointerException("Null code");
                                            }
                                        } else if (b5 != 2) {
                                            jsonReader.skipValue();
                                        } else {
                                            lValueOf = Long.valueOf(jsonReader.nextLong());
                                        }
                                        lValueOf = lValueOf;
                                        strNextString2 = strNextString2;
                                        strNextString = strNextString;
                                    }
                                    jsonReader.endObject();
                                    String strM48792 = strNextString2 == 0 ? " name" : "";
                                    if (strNextString == 0) {
                                        strM48792 = C2803.m4879(strM48792, " code");
                                    }
                                    if (lValueOf == 0) {
                                        strM48792 = C2803.m4879(strM48792, " address");
                                    }
                                    if (!strM48792.isEmpty()) {
                                        throw new IllegalStateException(C2803.m4879("Missing required properties:", strM48792));
                                    }
                                    c5759.f16437 = new C5764(strNextString2, strNextString, lValueOf.longValue(), null);
                                } else if (b4 != c) {
                                    jsonReader.skipValue();
                                } else {
                                    c5759.f16438 = m9112(jsonReader, new InterfaceC5817() { // from class: ދ.ހ.ށ.ބ.ށ.މ.ޕ.ހ
                                        @Override // p138.p176.p291.p296.p297.p301.p302.C5816.InterfaceC5817
                                        /* JADX INFO: renamed from: ֏ */
                                        public Object mo9110(JsonReader jsonReader2) {
                                            return C5816.m9116(jsonReader2);
                                        }
                                    });
                                }
                                c = 3;
                                c5775 = null;
                            }
                            jsonReader.endObject();
                            abstractC5794Mo9103 = c5759.mo9103();
                        } else if (b3 != c) {
                            jsonReader.skipValue();
                        } else {
                            c5810M9112 = m9112(jsonReader, new InterfaceC5817() { // from class: ދ.ހ.ށ.ބ.ށ.މ.ޕ.֏
                                @Override // p138.p176.p291.p296.p297.p301.p302.C5816.InterfaceC5817
                                /* JADX INFO: renamed from: ֏, reason: contains not printable characters */
                                public Object mo9110(JsonReader jsonReader2) {
                                    return C5816.m9114(jsonReader2);
                                }
                            });
                        }
                        c = 3;
                        c5775 = null;
                    }
                    jsonReader.endObject();
                    strM4879 = abstractC5794Mo9103 == null ? " execution" : "";
                    if (numValueOf == null) {
                        strM4879 = C2803.m4879(strM4879, " uiOrientation");
                    }
                    if (!strM4879.isEmpty()) {
                        throw new IllegalStateException(C2803.m4879("Missing required properties:", strM4879));
                    }
                    c5754.mo9101(new C5755(abstractC5794Mo9103, c5810M9112, boolValueOf, numValueOf.intValue(), null));
                } else if (b == 3) {
                    C5771.C5773 c5773 = new C5771.C5773();
                    jsonReader.beginObject();
                    while (jsonReader.hasNext()) {
                        String strNextName5 = jsonReader.nextName();
                        switch (strNextName5.hashCode()) {
                            case -1708606089:
                                b2 = !strNextName5.equals("batteryLevel") ? (byte) -1 : (byte) 0;
                                break;
                            case -1455558134:
                                if (strNextName5.equals("batteryVelocity")) {
                                    b2 = 1;
                                    break;
                                }
                                break;
                            case -1439500848:
                                if (strNextName5.equals("orientation")) {
                                    b2 = 4;
                                    break;
                                }
                                break;
                            case 279795450:
                                if (strNextName5.equals("diskUsed")) {
                                    b2 = 2;
                                    break;
                                }
                                break;
                            case 976541947:
                                if (strNextName5.equals("ramUsed")) {
                                    b2 = 5;
                                    break;
                                }
                                break;
                            case 1516795582:
                                if (strNextName5.equals("proximityOn")) {
                                    b2 = 3;
                                    break;
                                }
                                break;
                        }
                        if (b2 == 0) {
                            c5773.f16470 = Double.valueOf(jsonReader.nextDouble());
                        } else if (b2 == 1) {
                            c5773.f16471 = Integer.valueOf(jsonReader.nextInt());
                        } else if (b2 == 2) {
                            c5773.f16475 = Long.valueOf(jsonReader.nextLong());
                        } else if (b2 == 3) {
                            c5773.f16472 = Boolean.valueOf(jsonReader.nextBoolean());
                        } else if (b2 == 4) {
                            c5773.f16473 = Integer.valueOf(jsonReader.nextInt());
                        } else if (b2 != 5) {
                            jsonReader.skipValue();
                        } else {
                            c5773.f16474 = Long.valueOf(jsonReader.nextLong());
                        }
                    }
                    jsonReader.endObject();
                    c5754.f16425 = c5773.mo9105();
                } else if (b != 4) {
                    jsonReader.skipValue();
                } else {
                    jsonReader.beginObject();
                    String strNextString3 = null;
                    while (jsonReader.hasNext()) {
                        String strNextName6 = jsonReader.nextName();
                        if (((strNextName6.hashCode() == 951530617 && strNextName6.equals("content")) ? (byte) 0 : (byte) -1) != 0) {
                            jsonReader.skipValue();
                        } else {
                            strNextString3 = jsonReader.nextString();
                            if (strNextString3 == null) {
                                throw new NullPointerException("Null content");
                            }
                        }
                    }
                    jsonReader.endObject();
                    strM4879 = strNextString3 == null ? " content" : "";
                    if (!strM4879.isEmpty()) {
                        throw new IllegalStateException(C2803.m4879("Missing required properties:", strM4879));
                    }
                    c5754.f16426 = new C5774(strNextString3, c5775);
                }
            } else {
                String strNextString4 = jsonReader.nextString();
                if (strNextString4 == null) {
                    throw new NullPointerException("Null type");
                }
                c5754.f16423 = strNextString4;
            }
        }
        jsonReader.endObject();
        return c5754.mo9102();
    }

    /* JADX WARN: Failed to restore switch over string. Please report as a decompilation issue */
    /* JADX INFO: renamed from: ރ, reason: contains not printable characters */
    public static AbstractC5781.AbstractC5786.AbstractC5792.AbstractC5793.AbstractC5794.AbstractC5797 m9118(JsonReader jsonReader) throws IOException {
        jsonReader.beginObject();
        Integer numValueOf = null;
        String strNextString = null;
        String strNextString2 = null;
        C5810 c5810M9112 = null;
        AbstractC5781.AbstractC5786.AbstractC5792.AbstractC5793.AbstractC5794.AbstractC5797 abstractC5797M9118 = null;
        while (jsonReader.hasNext()) {
            String strNextName = jsonReader.nextName();
            byte b = -1;
            switch (strNextName.hashCode()) {
                case -1266514778:
                    if (strNextName.equals("frames")) {
                        b = 1;
                    }
                    break;
                case -934964668:
                    if (strNextName.equals("reason")) {
                        b = 4;
                    }
                    break;
                case 3575610:
                    if (strNextName.equals("type")) {
                        b = 3;
                    }
                    break;
                case 91997906:
                    if (strNextName.equals("causedBy")) {
                        b = 0;
                    }
                    break;
                case 581754413:
                    if (strNextName.equals("overflowCount")) {
                        b = 2;
                    }
                    break;
            }
            if (b == 0) {
                abstractC5797M9118 = m9118(jsonReader);
            } else if (b == 1) {
                c5810M9112 = m9112(jsonReader, new InterfaceC5817() { // from class: ދ.ހ.ށ.ބ.ށ.މ.ޕ.ށ
                    @Override // p138.p176.p291.p296.p297.p301.p302.C5816.InterfaceC5817
                    /* JADX INFO: renamed from: ֏ */
                    public Object mo9110(JsonReader jsonReader2) {
                        return C5816.m9119(jsonReader2);
                    }
                });
            } else if (b == 2) {
                numValueOf = Integer.valueOf(jsonReader.nextInt());
            } else if (b == 3) {
                strNextString = jsonReader.nextString();
                if (strNextString == null) {
                    throw new NullPointerException("Null type");
                }
            } else if (b != 4) {
                jsonReader.skipValue();
            } else {
                strNextString2 = jsonReader.nextString();
            }
        }
        jsonReader.endObject();
        String strM4879 = strNextString == null ? " type" : "";
        if (c5810M9112 == null) {
            strM4879 = C2803.m4879(strM4879, " frames");
        }
        if (numValueOf == null) {
            strM4879 = C2803.m4879(strM4879, " overflowCount");
        }
        if (strM4879.isEmpty()) {
            return new C5762(strNextString, strNextString2, c5810M9112, abstractC5797M9118, numValueOf.intValue(), null);
        }
        throw new IllegalStateException(C2803.m4879("Missing required properties:", strM4879));
    }

    /* JADX WARN: Failed to restore switch over string. Please report as a decompilation issue */
    /* JADX INFO: renamed from: ބ, reason: contains not printable characters */
    public static AbstractC5781.AbstractC5786.AbstractC5792.AbstractC5793.AbstractC5794.AbstractC5799.AbstractC5800 m9119(JsonReader jsonReader) throws IOException {
        C5768.C5770 c5770 = new C5768.C5770();
        jsonReader.beginObject();
        while (jsonReader.hasNext()) {
            String strNextName = jsonReader.nextName();
            byte b = -1;
            switch (strNextName.hashCode()) {
                case -1019779949:
                    if (strNextName.equals("offset")) {
                        b = 2;
                    }
                    break;
                case -887523944:
                    if (strNextName.equals("symbol")) {
                        b = 4;
                    }
                    break;
                case 3571:
                    if (strNextName.equals("pc")) {
                        b = 3;
                    }
                    break;
                case 3143036:
                    if (strNextName.equals("file")) {
                        b = 1;
                    }
                    break;
                case 2125650548:
                    if (strNextName.equals("importance")) {
                        b = 0;
                    }
                    break;
            }
            if (b == 0) {
                c5770.f16463 = Integer.valueOf(jsonReader.nextInt());
            } else if (b == 1) {
                c5770.f16461 = jsonReader.nextString();
            } else if (b == 2) {
                c5770.f16462 = Long.valueOf(jsonReader.nextLong());
            } else if (b == 3) {
                c5770.f16459 = Long.valueOf(jsonReader.nextLong());
            } else if (b != 4) {
                jsonReader.skipValue();
            } else {
                String strNextString = jsonReader.nextString();
                if (strNextString == null) {
                    throw new NullPointerException("Null symbol");
                }
                c5770.f16460 = strNextString;
            }
        }
        jsonReader.endObject();
        return c5770.mo9104();
    }

    /* JADX WARN: Can't fix incorrect switch cases order, some code will duplicate */
    /* JADX WARN: Failed to restore switch over string. Please report as a decompilation issue */
    /* JADX WARN: Removed duplicated region for block: B:107:0x018e  */
    /* JADX WARN: Removed duplicated region for block: B:150:0x0242  */
    /* JADX WARN: Removed duplicated region for block: B:193:0x030e  */
    /* JADX WARN: Removed duplicated region for block: B:231:0x039f  */
    /* JADX WARN: Removed duplicated region for block: B:32:0x006c  */
    /* JADX WARN: Removed duplicated region for block: B:50:0x00ad  */
    /* JADX INFO: renamed from: ޅ, reason: contains not printable characters */
    /*
        Code decompiled incorrectly, please refer to instructions dump.
    */
    public static AbstractC5781 m9120(JsonReader jsonReader) throws IOException {
        byte b;
        byte b2;
        byte b3;
        byte b4;
        AbstractC5781.AbstractC5782 abstractC5782M9107 = AbstractC5781.m9107();
        jsonReader.beginObject();
        while (jsonReader.hasNext()) {
            String strNextName = jsonReader.nextName();
            boolean z = true;
            switch (strNextName.hashCode()) {
                case -2118372775:
                    b = !strNextName.equals("ndkPayload") ? (byte) -1 : (byte) 7;
                    break;
                case -1962630338:
                    if (strNextName.equals("sdkVersion")) {
                        b = 0;
                        break;
                    }
                    break;
                case -911706486:
                    if (strNextName.equals("buildVersion")) {
                        b = 4;
                        break;
                    }
                    break;
                case 344431858:
                    if (strNextName.equals("gmpAppId")) {
                        b = 1;
                        break;
                    }
                    break;
                case 719853845:
                    if (strNextName.equals("installationUuid")) {
                        b = 3;
                        break;
                    }
                    break;
                case 1874684019:
                    if (strNextName.equals("platform")) {
                        b = 2;
                        break;
                    }
                    break;
                case 1975623094:
                    if (strNextName.equals("displayVersion")) {
                        b = 5;
                        break;
                    }
                    break;
                case 1984987798:
                    if (strNextName.equals("session")) {
                        b = 6;
                        break;
                    }
                    break;
            }
            C5739.C5740 c5740 = null;
            switch (b) {
                case 0:
                    String strNextString = jsonReader.nextString();
                    C5734.C5736 c5736 = (C5734.C5736) abstractC5782M9107;
                    if (strNextString == null) {
                        throw new NullPointerException("Null sdkVersion");
                    }
                    c5736.f16358 = strNextString;
                    break;
                    break;
                case 1:
                    String strNextString2 = jsonReader.nextString();
                    C5734.C5736 c57362 = (C5734.C5736) abstractC5782M9107;
                    if (strNextString2 == null) {
                        throw new NullPointerException("Null gmpAppId");
                    }
                    c57362.f16359 = strNextString2;
                    break;
                    break;
                case 2:
                    ((C5734.C5736) abstractC5782M9107).f16360 = Integer.valueOf(jsonReader.nextInt());
                    break;
                case 3:
                    String strNextString3 = jsonReader.nextString();
                    C5734.C5736 c57363 = (C5734.C5736) abstractC5782M9107;
                    if (strNextString3 == null) {
                        throw new NullPointerException("Null installationUuid");
                    }
                    c57363.f16361 = strNextString3;
                    break;
                    break;
                case 4:
                    String strNextString4 = jsonReader.nextString();
                    C5734.C5736 c57364 = (C5734.C5736) abstractC5782M9107;
                    if (strNextString4 == null) {
                        throw new NullPointerException("Null buildVersion");
                    }
                    c57364.f16362 = strNextString4;
                    break;
                    break;
                case 5:
                    String strNextString5 = jsonReader.nextString();
                    C5734.C5736 c57365 = (C5734.C5736) abstractC5782M9107;
                    if (strNextString5 == null) {
                        throw new NullPointerException("Null displayVersion");
                    }
                    c57365.f16363 = strNextString5;
                    break;
                    break;
                case 6:
                    C5743.C5745 c5745 = new C5743.C5745();
                    c5745.mo9098(false);
                    jsonReader.beginObject();
                    while (jsonReader.hasNext()) {
                        switch (jsonReader.nextName()) {
                            case "generator":
                                String strNextString6 = jsonReader.nextString();
                                if (strNextString6 == null) {
                                    throw new NullPointerException("Null generator");
                                }
                                c5745.f16383 = strNextString6;
                                break;
                                break;
                            case "identifier":
                                c5745.f16384 = new String(Base64.decode(jsonReader.nextString(), 2), AbstractC5781.f16486);
                                break;
                            case "startedAt":
                                c5745.f16385 = Long.valueOf(jsonReader.nextLong());
                                break;
                            case "endedAt":
                                c5745.f16386 = Long.valueOf(jsonReader.nextLong());
                                break;
                            case "crashed":
                                c5745.mo9098(jsonReader.nextBoolean());
                                break;
                            case "user":
                                jsonReader.beginObject();
                                String strNextString7 = null;
                                while (jsonReader.hasNext()) {
                                    String strNextName2 = jsonReader.nextName();
                                    if (((strNextName2.hashCode() == -1618432855 && strNextName2.equals("identifier")) ? (byte) 0 : (byte) -1) != 0) {
                                        jsonReader.skipValue();
                                    } else {
                                        strNextString7 = jsonReader.nextString();
                                        if (strNextString7 == null) {
                                            throw new NullPointerException("Null identifier");
                                        }
                                    }
                                }
                                jsonReader.endObject();
                                String str = strNextString7 == null ? " identifier" : "";
                                if (!str.isEmpty()) {
                                    throw new IllegalStateException(C2803.m4879("Missing required properties:", str));
                                }
                                c5745.f16389 = new C5779(strNextString7, null);
                                break;
                                break;
                            case "app":
                                jsonReader.beginObject();
                                String strNextString8 = null;
                                String strNextString9 = null;
                                String str2 = null;
                                String str3 = null;
                                while (jsonReader.hasNext()) {
                                    String strNextName3 = jsonReader.nextName();
                                    switch (strNextName3.hashCode()) {
                                        case -1618432855:
                                            b2 = !strNextName3.equals("identifier") ? (byte) -1 : (byte) 0;
                                            break;
                                        case 351608024:
                                            if (strNextName3.equals("version")) {
                                                b2 = 1;
                                                break;
                                            }
                                            break;
                                        case 719853845:
                                            if (strNextName3.equals("installationUuid")) {
                                                b2 = 3;
                                                break;
                                            }
                                            break;
                                        case 1975623094:
                                            if (strNextName3.equals("displayVersion")) {
                                                b2 = 2;
                                                break;
                                            }
                                            break;
                                    }
                                    if (b2 == 0) {
                                        String strNextString10 = jsonReader.nextString();
                                        if (strNextString10 == null) {
                                            throw new NullPointerException("Null identifier");
                                        }
                                        str2 = strNextString10;
                                    } else if (b2 == z) {
                                        String strNextString11 = jsonReader.nextString();
                                        if (strNextString11 == null) {
                                            throw new NullPointerException("Null version");
                                        }
                                        str3 = strNextString11;
                                    } else if (b2 == 2) {
                                        strNextString8 = jsonReader.nextString();
                                    } else if (b2 != 3) {
                                        jsonReader.skipValue();
                                    } else {
                                        strNextString9 = jsonReader.nextString();
                                    }
                                    z = true;
                                }
                                jsonReader.endObject();
                                String strM4879 = str2 == null ? " identifier" : "";
                                if (str3 == null) {
                                    strM4879 = C2803.m4879(strM4879, " version");
                                }
                                if (!strM4879.isEmpty()) {
                                    throw new IllegalStateException(C2803.m4879("Missing required properties:", strM4879));
                                }
                                c5745.f16388 = new C5746(str2, str3, strNextString8, null, strNextString9, null);
                                break;
                                break;
                            case "os":
                                C5776.C5778 c5778 = new C5776.C5778();
                                jsonReader.beginObject();
                                while (jsonReader.hasNext()) {
                                    String strNextName4 = jsonReader.nextName();
                                    switch (strNextName4.hashCode()) {
                                        case -911706486:
                                            b3 = !strNextName4.equals("buildVersion") ? (byte) -1 : (byte) 2;
                                            break;
                                        case -293026577:
                                            if (strNextName4.equals("jailbroken")) {
                                                b3 = 3;
                                                break;
                                            }
                                            break;
                                        case 351608024:
                                            if (strNextName4.equals("version")) {
                                                b3 = 1;
                                                break;
                                            }
                                            break;
                                        case 1874684019:
                                            if (strNextName4.equals("platform")) {
                                                b3 = 0;
                                                break;
                                            }
                                            break;
                                    }
                                    if (b3 == 0) {
                                        c5778.f16481 = Integer.valueOf(jsonReader.nextInt());
                                    } else if (b3 == z) {
                                        String strNextString12 = jsonReader.nextString();
                                        if (strNextString12 == null) {
                                            throw new NullPointerException("Null version");
                                        }
                                        c5778.f16482 = strNextString12;
                                    } else if (b3 == 2) {
                                        String strNextString13 = jsonReader.nextString();
                                        if (strNextString13 == null) {
                                            throw new NullPointerException("Null buildVersion");
                                        }
                                        c5778.f16483 = strNextString13;
                                    } else if (b3 != 3) {
                                        jsonReader.skipValue();
                                    } else {
                                        c5778.f16484 = Boolean.valueOf(jsonReader.nextBoolean());
                                    }
                                }
                                jsonReader.endObject();
                                c5745.f16390 = c5778.mo9106();
                                break;
                            case "device":
                                C5749.C5751 c5751 = new C5749.C5751();
                                jsonReader.beginObject();
                                while (jsonReader.hasNext()) {
                                    switch (jsonReader.nextName()) {
                                        case "arch":
                                            c5751.f16408 = Integer.valueOf(jsonReader.nextInt());
                                            break;
                                        case "model":
                                            String strNextString14 = jsonReader.nextString();
                                            if (strNextString14 == null) {
                                                throw new NullPointerException("Null model");
                                            }
                                            c5751.f16409 = strNextString14;
                                            break;
                                            break;
                                        case "cores":
                                            c5751.f16410 = Integer.valueOf(jsonReader.nextInt());
                                            break;
                                        case "ram":
                                            c5751.f16411 = Long.valueOf(jsonReader.nextLong());
                                            break;
                                        case "diskSpace":
                                            c5751.f16412 = Long.valueOf(jsonReader.nextLong());
                                            break;
                                        case "simulator":
                                            c5751.f16413 = Boolean.valueOf(jsonReader.nextBoolean());
                                            break;
                                        case "state":
                                            c5751.f16414 = Integer.valueOf(jsonReader.nextInt());
                                            break;
                                        case "manufacturer":
                                            String strNextString15 = jsonReader.nextString();
                                            if (strNextString15 == null) {
                                                throw new NullPointerException("Null manufacturer");
                                            }
                                            c5751.f16415 = strNextString15;
                                            break;
                                            break;
                                        case "modelClass":
                                            String strNextString16 = jsonReader.nextString();
                                            if (strNextString16 == null) {
                                                throw new NullPointerException("Null modelClass");
                                            }
                                            c5751.f16416 = strNextString16;
                                            break;
                                            break;
                                        default:
                                            jsonReader.skipValue();
                                            break;
                                    }
                                }
                                jsonReader.endObject();
                                c5745.f16391 = c5751.mo9100();
                                break;
                            case "events":
                                ArrayList arrayList = new ArrayList();
                                jsonReader.beginArray();
                                while (jsonReader.hasNext()) {
                                    arrayList.add(m9117(jsonReader));
                                }
                                jsonReader.endArray();
                                c5745.f16392 = new C5810<>(arrayList);
                                break;
                            case "generatorType":
                                c5745.f16393 = Integer.valueOf(jsonReader.nextInt());
                                break;
                            default:
                                jsonReader.skipValue();
                                break;
                        }
                        z = true;
                    }
                    jsonReader.endObject();
                    ((C5734.C5736) abstractC5782M9107).f16364 = c5745.mo9099();
                    break;
                case 7:
                    jsonReader.beginObject();
                    C5810 c5810 = null;
                    String strNextString17 = null;
                    while (jsonReader.hasNext()) {
                        String strNextName5 = jsonReader.nextName();
                        int iHashCode = strNextName5.hashCode();
                        if (iHashCode != 97434231) {
                            b4 = (iHashCode == 106008351 && strNextName5.equals("orgId")) ? (byte) 1 : (byte) -1;
                        } else if (strNextName5.equals("files")) {
                            b4 = 0;
                        }
                        if (b4 == 0) {
                            ArrayList arrayList2 = new ArrayList();
                            jsonReader.beginArray();
                            while (jsonReader.hasNext()) {
                                arrayList2.add(m9111(jsonReader));
                            }
                            jsonReader.endArray();
                            c5810 = new C5810(arrayList2);
                        } else if (b4 != 1) {
                            jsonReader.skipValue();
                        } else {
                            strNextString17 = jsonReader.nextString();
                        }
                    }
                    jsonReader.endObject();
                    String str4 = c5810 == null ? " files" : "";
                    if (!str4.isEmpty()) {
                        throw new IllegalStateException(C2803.m4879("Missing required properties:", str4));
                    }
                    ((C5734.C5736) abstractC5782M9107).f16365 = new C5739(c5810, strNextString17, c5740);
                    break;
                    break;
                default:
                    jsonReader.skipValue();
                    break;
            }
        }
        jsonReader.endObject();
        return abstractC5782M9107.mo9097();
    }

    /* JADX INFO: renamed from: ֏, reason: contains not printable characters */
    public String m9121(AbstractC5781 abstractC5781) {
        C5892 c5892 = (C5892) f16497;
        if (c5892 == null) {
            throw null;
        }
        StringWriter stringWriter = new StringWriter();
        try {
            c5892.m9223(abstractC5781, stringWriter);
        } catch (IOException unused) {
        }
        return stringWriter.toString();
    }

    /* JADX INFO: renamed from: ֏, reason: contains not printable characters */
    public AbstractC5781 m9122(String str) throws Exception {
        try {
            JsonReader jsonReader = new JsonReader(new StringReader(str));
            try {
                AbstractC5781 abstractC5781M9120 = m9120(jsonReader);
                m9113((Throwable) null, jsonReader);
                return abstractC5781M9120;
            } finally {
            }
        } catch (IllegalStateException e) {
            throw new IOException(e);
        }
    }
}
