package com.martsnew.data.model.request;

import B6.v;
import P6.g;
import d5.AbstractC0844a;
import e0.C0853a;
import java.util.List;
import o6.AbstractC1380C;
import o6.AbstractC1391k;
import o6.AbstractC1394n;
import o6.AbstractC1397q;
import o6.x;
import p6.AbstractC1439e;

/* JADX INFO: loaded from: classes.dex */
public final class ReportRequestJsonAdapter extends AbstractC1391k {

    /* JADX INFO: renamed from: a, reason: collision with root package name */
    public final C0853a f10639a;

    /* JADX INFO: renamed from: b, reason: collision with root package name */
    public final AbstractC1391k f10640b;

    /* JADX INFO: renamed from: c, reason: collision with root package name */
    public final AbstractC1391k f10641c;

    /* JADX INFO: renamed from: d, reason: collision with root package name */
    public final AbstractC1391k f10642d;

    public ReportRequestJsonAdapter(x xVar) {
        g.e(xVar, "moshi");
        this.f10639a = C0853a.B("movie_id", "topics", "message");
        v vVar = v.f1034q;
        this.f10640b = xVar.b(Long.TYPE, vVar, "movieId");
        this.f10641c = xVar.b(AbstractC1380C.f(Long.class), vVar, "topicIds");
        this.f10642d = xVar.b(String.class, vVar, "message");
    }

    @Override // o6.AbstractC1391k
    public final Object b(AbstractC1394n abstractC1394n) {
        g.e(abstractC1394n, "reader");
        abstractC1394n.b();
        Long l8 = null;
        List list = null;
        String str = null;
        while (abstractC1394n.n()) {
            int iQ = abstractC1394n.Q(this.f10639a);
            if (iQ == -1) {
                abstractC1394n.V();
                abstractC1394n.f0();
            } else if (iQ == 0) {
                l8 = (Long) this.f10640b.b(abstractC1394n);
                if (l8 == null) {
                    throw AbstractC1439e.j("movieId", "movie_id", abstractC1394n);
                }
            } else if (iQ == 1) {
                list = (List) this.f10641c.b(abstractC1394n);
                if (list == null) {
                    throw AbstractC1439e.j("topicIds", "topics", abstractC1394n);
                }
            } else if (iQ == 2) {
                str = (String) this.f10642d.b(abstractC1394n);
            }
        }
        abstractC1394n.j();
        if (l8 == null) {
            throw AbstractC1439e.e("movieId", "movie_id", abstractC1394n);
        }
        long jLongValue = l8.longValue();
        if (list != null) {
            return new ReportRequest(jLongValue, list, str);
        }
        throw AbstractC1439e.e("topicIds", "topics", abstractC1394n);
    }

    @Override // o6.AbstractC1391k
    public final void e(AbstractC1397q abstractC1397q, Object obj) {
        ReportRequest reportRequest = (ReportRequest) obj;
        g.e(abstractC1397q, "writer");
        if (reportRequest == null) {
            throw new NullPointerException("value_ was null! Wrap in .nullSafe() to write nullable values.");
        }
        abstractC1397q.b();
        abstractC1397q.m("movie_id");
        this.f10640b.e(abstractC1397q, Long.valueOf(reportRequest.f10636a));
        abstractC1397q.m("topics");
        this.f10641c.e(abstractC1397q, reportRequest.f10637b);
        abstractC1397q.m("message");
        this.f10642d.e(abstractC1397q, reportRequest.f10638c);
        abstractC1397q.g();
    }

    public final String toString() {
        return AbstractC0844a.h(35, "GeneratedJsonAdapter(ReportRequest)");
    }
}
