package com.bytedance.common.wschannel.model;

import X.C1070PZz;
import X.C1071Pa0;
import X.C1073Pa2;
import X.PBO;
import X.Q1J;
import com.bytedance.covode.number.Covode;
import com.squareup.wire.Message;
import com.squareup.wire.ProtoAdapter;
import com.squareup.wire.WireField;
import java.util.List;

public final class Frame extends Message<Frame, C1073Pa2> {
    public static final ProtoAdapter<Frame> ADAPTER = new C1070PZz();
    public static final Long DEFAULT_LOGID = 0L;
    public static final Integer DEFAULT_METHOD = 0;
    public static final Q1J DEFAULT_PAYLOAD = Q1J.EMPTY;
    public static final Long DEFAULT_SEQID = 0L;
    public static final Integer DEFAULT_SERVICE = 0;
    public static final long serialVersionUID = 0;
    @WireField(adapter = "com.bytedance.article.wschannel.model.Frame$ExtendedEntry#ADAPTER", label = WireField.Label.REPEATED, tag = 5)
    public final List<C1071Pa0> headers;
    @WireField(adapter = "com.squareup.wire.ProtoAdapter#UINT64", label = WireField.Label.REQUIRED, tag = 2)
    public final Long logid;
    @WireField(adapter = "com.squareup.wire.ProtoAdapter#INT32", label = WireField.Label.REQUIRED, tag = 4)
    public final Integer method;
    @WireField(adapter = "com.squareup.wire.ProtoAdapter#BYTES", tag = 8)
    public final Q1J payload;
    @WireField(adapter = "com.squareup.wire.ProtoAdapter#STRING", tag = 6)
    public final String payload_encoding;
    @WireField(adapter = "com.squareup.wire.ProtoAdapter#STRING", tag = 7)
    public final String payload_type;
    @WireField(adapter = "com.squareup.wire.ProtoAdapter#UINT64", label = WireField.Label.REQUIRED, tag = 1)
    public final Long seqid;
    @WireField(adapter = "com.squareup.wire.ProtoAdapter#INT32", label = WireField.Label.REQUIRED, tag = 3)
    public final Integer service;

    static {
        Covode.recordClassIndex(24938);
    }

    public final C1073Pa2 newBuilder() {
        C1073Pa2 pa2 = new C1073Pa2();
        pa2.LIZ = this.seqid;
        pa2.LIZIZ = this.logid;
        pa2.LIZJ = this.service;
        pa2.LIZLLL = this.method;
        pa2.LJ = PBO.LIZ("headers", this.headers);
        pa2.LJFF = this.payload_encoding;
        pa2.LJI = this.payload_type;
        pa2.LJII = this.payload;
        pa2.addUnknownFields(unknownFields());
        return pa2;
    }

    public final int hashCode() {
        int i;
        int i2;
        int i3 = this.hashCode;
        if (i3 != 0) {
            return i3;
        }
        int hashCode = ((((((((((unknownFields().hashCode() * 37) + this.seqid.hashCode()) * 37) + this.logid.hashCode()) * 37) + this.service.hashCode()) * 37) + this.method.hashCode()) * 37) + this.headers.hashCode()) * 37;
        String str = this.payload_encoding;
        int i4 = 0;
        if (str != null) {
            i = str.hashCode();
        } else {
            i = 0;
        }
        int i5 = (hashCode + i) * 37;
        String str2 = this.payload_type;
        if (str2 != null) {
            i2 = str2.hashCode();
        } else {
            i2 = 0;
        }
        int i6 = (i5 + i2) * 37;
        Q1J q1j = this.payload;
        if (q1j != null) {
            i4 = q1j.hashCode();
        }
        int i7 = i6 + i4;
        this.hashCode = i7;
        return i7;
    }

    public final String toString() {
        StringBuilder sb = new StringBuilder();
        sb.append(", seqid=");
        sb.append(this.seqid);
        sb.append(", logid=");
        sb.append(this.logid);
        sb.append(", service=");
        sb.append(this.service);
        sb.append(", method=");
        sb.append(this.method);
        if (!this.headers.isEmpty()) {
            sb.append(", headers=");
            sb.append(this.headers);
        }
        if (this.payload_encoding != null) {
            sb.append(", payload_encoding=");
            sb.append(this.payload_encoding);
        }
        if (this.payload_type != null) {
            sb.append(", payload_type=");
            sb.append(this.payload_type);
        }
        if (this.payload != null) {
            sb.append(", payload=");
            sb.append(this.payload);
        }
        sb.replace(0, 2, "Frame{");
        sb.append('}');
        return sb.toString();
    }

    public final boolean equals(Object obj) {
        if (obj == this) {
            return true;
        }
        if (!(obj instanceof Frame)) {
            return false;
        }
        Frame frame = (Frame) obj;
        if (!unknownFields().equals(frame.unknownFields()) || !this.seqid.equals(frame.seqid) || !this.logid.equals(frame.logid) || !this.service.equals(frame.service) || !this.method.equals(frame.method) || !this.headers.equals(frame.headers) || !PBO.LIZ((Object) this.payload_encoding, (Object) frame.payload_encoding) || !PBO.LIZ((Object) this.payload_type, (Object) frame.payload_type) || !PBO.LIZ((Object) this.payload, (Object) frame.payload)) {
            return false;
        }
        return true;
    }

    /* JADX WARNING: Illegal instructions before constructor call */
    /* Code decompiled incorrectly, please refer to instructions dump. */
    public Frame(java.lang.Long r11, java.lang.Long r12, java.lang.Integer r13, java.lang.Integer r14, java.util.List<X.C1071Pa0> r15, java.lang.String r16, java.lang.String r17, X.Q1J r18) {
        /*
            r10 = this;
            X.Q1J r9 = X.Q1J.EMPTY
            r0 = r10
            r6 = r16
            r5 = r15
            r7 = r17
            r8 = r18
            r1 = r11
            r2 = r12
            r3 = r13
            r4 = r14
            r0.<init>(r1, r2, r3, r4, r5, r6, r7, r8, r9)
            return
        */
        throw new UnsupportedOperationException("Method not decompiled: com.bytedance.common.wschannel.model.Frame.<init>(java.lang.Long, java.lang.Long, java.lang.Integer, java.lang.Integer, java.util.List, java.lang.String, java.lang.String, X.Q1J):void");
    }

    public Frame(Long l, Long l2, Integer num, Integer num2, List<C1071Pa0> list, String str, String str2, Q1J q1j, Q1J q1j2) {
        super(ADAPTER, q1j2);
        this.seqid = l;
        this.logid = l2;
        this.service = num;
        this.method = num2;
        this.headers = PBO.LIZIZ("headers", list);
        this.payload_encoding = str;
        this.payload_type = str2;
        this.payload = q1j;
    }
}
