package defpackage;

import j$.util.Objects;

/* JADX INFO: renamed from: ᵥᵣᵫ, reason: contains not printable characters */
/* JADX INFO: loaded from: classes3.dex */
public final class C3518 implements Comparable {

    /* JADX INFO: renamed from: ˌᴵ, reason: contains not printable characters */
    public final long f13505;

    /* JADX INFO: renamed from: ᵔᵖᵹᵫ, reason: contains not printable characters */
    public final int f13506;

    /* JADX INFO: renamed from: ᵜᵪʾ, reason: contains not printable characters */
    public final String f13507;

    /* JADX INFO: renamed from: ᵨᵼⁱ, reason: contains not printable characters */
    public final long f13508;

    /* JADX INFO: renamed from: ᵯᵷʽ, reason: contains not printable characters */
    public final Object f13509;

    /* JADX INFO: renamed from: ᵶˇᵱ, reason: contains not printable characters */
    public final RuntimeException f13510;

    public C3518(long j, String str, int i, long j2, Object obj) {
        ᵻᵪ.ᵱᵽʡᵚ(((j > 0L ? 1 : (j == 0L ? 0 : -1)) == 0) == (str != null));
        this.f13505 = j;
        this.f13507 = str;
        this.f13506 = i;
        this.f13508 = j2;
        this.f13509 = obj;
        if (i != 5) {
            this.f13510 = null;
            return;
        }
        if (obj == null) {
            this.f13510 = new NullPointerException("Null stringOrBytes");
        } else if ((obj instanceof byte[]) || (obj instanceof AbstractC4667)) {
            this.f13510 = null;
        } else {
            this.f13510 = new RuntimeException("Wrong stringOrBytes type: ".concat(String.valueOf(obj.getClass())));
        }
    }

    @Override // java.lang.Comparable
    public final int compareTo(Object obj) {
        C3518 c3518 = (C3518) obj;
        long j = c3518.f13505;
        long j2 = this.f13505;
        int iCompare = Long.compare(j2, j);
        if (iCompare != 0) {
            return iCompare;
        }
        if (j2 != 0) {
            return 0;
        }
        String str = this.f13507;
        str.getClass();
        String str2 = c3518.f13507;
        str2.getClass();
        return str.compareTo(str2);
    }

    public final boolean equals(Object obj) {
        if (this == obj) {
            return true;
        }
        if (!(obj instanceof C3518)) {
            return false;
        }
        C3518 c3518 = (C3518) obj;
        return this.f13505 == c3518.f13505 && Objects.equals(this.f13507, c3518.f13507);
    }

    public final int hashCode() {
        return Objects.hash(Long.valueOf(this.f13505), this.f13507);
    }

    public final String toString() {
        String string = this.f13507;
        if (string == null) {
            string = Long.toString(this.f13505);
        }
        String strValueOf = String.valueOf(m8018());
        return AbstractC0793.m2864(new StringBuilder(String.valueOf(string).length() + 1 + strValueOf.length()), string, ":", strValueOf);
    }

    /* JADX INFO: renamed from: ᵲᵶᵳˈ, reason: contains not printable characters */
    public final Object m8018() {
        int i = this.f13506;
        if (i == 0) {
            return Boolean.FALSE;
        }
        if (i == 1) {
            return Boolean.TRUE;
        }
        long j = this.f13508;
        if (i == 2) {
            return Long.valueOf(j);
        }
        if (i == 3) {
            return Double.valueOf(Double.longBitsToDouble(j));
        }
        Object obj = this.f13509;
        if (i == 4) {
            obj.getClass();
            return obj;
        }
        if (i != 5) {
            throw new AssertionError("Impossible, this was validated when parsed or created");
        }
        obj.getClass();
        try {
            return obj instanceof byte[] ? (byte[]) obj : ((AbstractC4667) obj).m9797();
        } catch (Throwable th) {
            RuntimeException runtimeException = this.f13510;
            if (runtimeException != null) {
                th.addSuppressed(runtimeException);
            }
            throw th;
        }
    }
}
