package F7;

import Z6.C0369i;
import com.google.android.gms.internal.measurement.C1;
import g3.InterfaceC0985c;
import java.lang.reflect.InvocationTargetException;
import n4.u0;

/* JADX INFO: renamed from: F7.w, reason: case insensitive filesystem */
/* JADX INFO: loaded from: classes.dex */
public final class C0138w implements InterfaceC0124h, InterfaceC0985c {

    /* JADX INFO: renamed from: q, reason: collision with root package name */
    public final /* synthetic */ int f2731q;

    /* JADX INFO: renamed from: r, reason: collision with root package name */
    public final /* synthetic */ C0369i f2732r;

    public /* synthetic */ C0138w(C0369i c0369i, int i) {
        this.f2731q = i;
        this.f2732r = c0369i;
    }

    @Override // g3.InterfaceC0985c
    public void a(g3.o oVar) throws IllegalAccessException, Z6.F, InvocationTargetException {
        Exception excF = oVar.f();
        if (excF != null) {
            this.f2732r.i(C1.j(excF));
        } else if (oVar.f12946d) {
            this.f2732r.q(null);
        } else {
            this.f2732r.i(oVar.g());
        }
    }

    @Override // F7.InterfaceC0124h
    public void p(InterfaceC0121e interfaceC0121e, T t6) throws IllegalAccessException, Z6.F, InvocationTargetException {
        switch (this.f2731q) {
            case u0.f15495q /* 0 */:
                P6.g.e(interfaceC0121e, "call");
                boolean zB = t6.f2677a.b();
                C0369i c0369i = this.f2732r;
                if (!zB) {
                    c0369i.i(C1.j(new C0133q(t6)));
                } else {
                    Object obj = t6.f2678b;
                    if (obj != null) {
                        c0369i.i(obj);
                    } else {
                        k7.y yVarG = interfaceC0121e.g();
                        yVarG.getClass();
                        Object objCast = C0136u.class.cast(yVarG.f14206e.get(C0136u.class));
                        P6.g.b(objCast);
                        C0136u c0136u = (C0136u) objCast;
                        c0369i.i(C1.j(new A6.c("Response from " + c0136u.f2725a.getName() + '.' + c0136u.f2727c.getName() + " was null but response body type was declared as non-null")));
                    }
                }
                break;
            case 1:
                P6.g.e(interfaceC0121e, "call");
                boolean zB2 = t6.f2677a.b();
                C0369i c0369i2 = this.f2732r;
                if (!zB2) {
                    c0369i2.i(C1.j(new C0133q(t6)));
                } else {
                    c0369i2.i(t6.f2678b);
                }
                break;
            default:
                P6.g.e(interfaceC0121e, "call");
                this.f2732r.i(t6);
                break;
        }
    }

    @Override // F7.InterfaceC0124h
    public void v(InterfaceC0121e interfaceC0121e, Throwable th) throws IllegalAccessException, Z6.F, InvocationTargetException {
        switch (this.f2731q) {
            case u0.f15495q /* 0 */:
                P6.g.e(interfaceC0121e, "call");
                this.f2732r.i(C1.j(th));
                break;
            case 1:
                P6.g.e(interfaceC0121e, "call");
                this.f2732r.i(C1.j(th));
                break;
            default:
                P6.g.e(interfaceC0121e, "call");
                this.f2732r.i(C1.j(th));
                break;
        }
    }
}
