package p491;

import java.lang.reflect.Method;
import kotlin.KotlinNullPointerException;
import p025.p026.InterfaceC1306;
import p138.p176.p177.p242.p246.p251.C4303;
import p402.C6542;
import p402.p411.p413.C6635;
import retrofit2.HttpException;

/* JADX INFO: Add missing generic type declarations: [T] */
/* JADX INFO: renamed from: ޓ.ދ, reason: contains not printable characters */
/* JADX INFO: loaded from: classes.dex */
public final class C7333<T> implements InterfaceC7313<T> {

    /* JADX INFO: renamed from: ֏, reason: contains not printable characters */
    public final /* synthetic */ InterfaceC1306 f21240;

    public C7333(InterfaceC1306 interfaceC1306) {
        this.f21240 = interfaceC1306;
    }

    @Override // p491.InterfaceC7313
    /* JADX INFO: renamed from: ֏ */
    public void mo10957(InterfaceC7310<T> interfaceC7310, Throwable th) {
        if (interfaceC7310 == null) {
            C6635.m9824("call");
            throw null;
        }
        if (th == null) {
            C6635.m9824("t");
            throw null;
        }
        InterfaceC1306 interfaceC1306 = this.f21240;
        C6542.C6543 c6543 = C6542.f19318;
        interfaceC1306.mo2608(C4303.m7010(th));
    }

    @Override // p491.InterfaceC7313
    /* JADX INFO: renamed from: ֏ */
    public void mo10958(InterfaceC7310<T> interfaceC7310, C7366<T> c7366) {
        if (interfaceC7310 == null) {
            C6635.m9824("call");
            throw null;
        }
        if (c7366 == null) {
            C6635.m9824("response");
            throw null;
        }
        if (!c7366.m10977()) {
            InterfaceC1306 interfaceC1306 = this.f21240;
            HttpException httpException = new HttpException(c7366);
            C6542.C6543 c6543 = C6542.f19318;
            interfaceC1306.mo2608(C4303.m7010((Throwable) httpException));
            return;
        }
        T t = c7366.f21357;
        if (t != null) {
            InterfaceC1306 interfaceC13062 = this.f21240;
            C6542.C6543 c65432 = C6542.f19318;
            interfaceC13062.mo2608(t);
            return;
        }
        Object objCast = C7330.class.cast(interfaceC7310.mo10952().f20132.get(C7330.class));
        if (objCast == null) {
            C6635.m9822();
            throw null;
        }
        C6635.m9823(objCast, "call.request().tag(Invocation::class.java)!!");
        Method method = ((C7330) objCast).f21236;
        StringBuilder sb = new StringBuilder();
        sb.append("Response from ");
        C6635.m9823((Object) method, "method");
        Class<?> declaringClass = method.getDeclaringClass();
        C6635.m9823((Object) declaringClass, "method.declaringClass");
        sb.append(declaringClass.getName());
        sb.append('.');
        sb.append(method.getName());
        sb.append(" was null but response body type was declared as non-null");
        KotlinNullPointerException kotlinNullPointerException = new KotlinNullPointerException(sb.toString());
        InterfaceC1306 interfaceC13063 = this.f21240;
        C6542.C6543 c65433 = C6542.f19318;
        interfaceC13063.mo2608(C4303.m7010((Throwable) kotlinNullPointerException));
    }
}
