package m5;

import T0.C0606q;
import l5.AbstractC2458c;

/* JADX INFO: loaded from: classes3.dex */
public final class h extends W.a {

    /* JADX INFO: renamed from: g, reason: collision with root package name */
    public final y f21250g;

    /* JADX INFO: renamed from: h, reason: collision with root package name */
    public final C0606q f21251h;

    public h(y yVar, AbstractC2458c json) {
        kotlin.jvm.internal.o.h(json, "json");
        this.f21250g = yVar;
        this.f21251h = json.f20334b;
    }

    @Override // W.a, j5.c
    public final short A() {
        w4.y yVar;
        y yVar2 = this.f21250g;
        String strJ = yVar2.j();
        try {
            kotlin.jvm.internal.o.h(strJ, "<this>");
            w4.t tVarT = A4.g.T(strJ);
            if (tVarT != null) {
                int i6 = tVarT.f25484a;
                yVar = Integer.compare(Integer.MIN_VALUE ^ i6, -2147418113) > 0 ? null : new w4.y((short) i6);
            }
            if (yVar != null) {
                return yVar.f25489a;
            }
            S4.w.u0(strJ);
            throw null;
        } catch (IllegalArgumentException unused) {
            y.m(yVar2, A0.a.k('\'', "Failed to parse type 'UShort' for input '", strJ), 0, null, 6);
            throw null;
        }
    }

    @Override // j5.a
    public final C0606q a() {
        return this.f21251h;
    }

    @Override // j5.a
    public final int k(i5.g descriptor) {
        kotlin.jvm.internal.o.h(descriptor, "descriptor");
        throw new IllegalStateException("unsupported");
    }

    @Override // W.a, j5.c
    public final int m() {
        y yVar = this.f21250g;
        String strJ = yVar.j();
        try {
            kotlin.jvm.internal.o.h(strJ, "<this>");
            w4.t tVarT = A4.g.T(strJ);
            if (tVarT != null) {
                return tVarT.f25484a;
            }
            S4.w.u0(strJ);
            throw null;
        } catch (IllegalArgumentException unused) {
            y.m(yVar, A0.a.k('\'', "Failed to parse type 'UInt' for input '", strJ), 0, null, 6);
            throw null;
        }
    }

    @Override // W.a, j5.c
    public final long s() {
        y yVar = this.f21250g;
        String strJ = yVar.j();
        try {
            kotlin.jvm.internal.o.h(strJ, "<this>");
            w4.v vVarU = A4.g.U(strJ);
            if (vVarU != null) {
                return vVarU.f25486a;
            }
            S4.w.u0(strJ);
            throw null;
        } catch (IllegalArgumentException unused) {
            y.m(yVar, A0.a.k('\'', "Failed to parse type 'ULong' for input '", strJ), 0, null, 6);
            throw null;
        }
    }

    @Override // W.a, j5.c
    public final byte z() {
        w4.r rVar;
        y yVar = this.f21250g;
        String strJ = yVar.j();
        try {
            kotlin.jvm.internal.o.h(strJ, "<this>");
            w4.t tVarT = A4.g.T(strJ);
            if (tVarT != null) {
                int i6 = tVarT.f25484a;
                rVar = Integer.compare(Integer.MIN_VALUE ^ i6, -2147483393) > 0 ? null : new w4.r((byte) i6);
            }
            if (rVar != null) {
                return rVar.f25482a;
            }
            S4.w.u0(strJ);
            throw null;
        } catch (IllegalArgumentException unused) {
            y.m(yVar, A0.a.k('\'', "Failed to parse type 'UByte' for input '", strJ), 0, null, 6);
            throw null;
        }
    }
}
