package nano;

import com.google.protobuf.nano.CodedInputByteBufferNano;
import com.google.protobuf.nano.CodedOutputByteBufferNano;
import com.google.protobuf.nano.InternalNano;
import com.google.protobuf.nano.InvalidProtocolBufferNanoException;
import com.google.protobuf.nano.MessageNano;
import com.google.protobuf.nano.WireFormatNano;
import java.io.IOException;
import nano.TopShareRequest;

/* compiled from: TbsSdkJava */
public interface TopShareResponse {

    /* compiled from: TbsSdkJava */
    public static final class TopShare_Response extends MessageNano {

        private static volatile TopShare_Response[] _emptyArray;

        public TopShareRequest.TopShare_Request input;

        public TopShareData output;

        /* compiled from: TbsSdkJava */
        public static final class TopShareData extends MessageNano {

            private static volatile TopShareData[] _emptyArray;

            private int bitField0_;

            public int[] calendarDate;

            private int date_;

            public TopDetail[] list;

            /* compiled from: TbsSdkJava */
            public static final class TopDetail extends MessageNano {

                private static volatile TopDetail[] _emptyArray;

                private int bitField0_;

                private long category_;

                private String code_;

                private int exchange_;

                private int id_;

                private String name_;

                private int ratio_;

                private int session_;

                private long value_;

                public TopDetail() {
                    clear();
                }

                public static TopDetail[] emptyArray() {
                    if (_emptyArray == null) {
                        synchronized (InternalNano.LAZY_INIT_LOCK) {
                            try {
                                if (_emptyArray == null) {
                                    _emptyArray = new TopDetail[0];
                                }
                            } catch (Throwable th) {
                                throw th;
                            }
                        }
                    }
                    return _emptyArray;
                }

                public static TopDetail parseFrom(byte[] bArr) throws InvalidProtocolBufferNanoException {
                    return (TopDetail) MessageNano.mergeFrom(new TopDetail(), bArr);
                }

                public TopDetail clear() {
                    this.bitField0_ = 0;
                    this.id_ = 0;
                    this.code_ = "";
                    this.name_ = "";
                    this.exchange_ = 0;
                    this.category_ = 0;
                    this.session_ = 0;
                    this.value_ = 0;
                    this.ratio_ = 0;
                    this.cachedSize = -1;
                    return this;
                }

                public TopDetail clearCategory() {
                    this.category_ = 0;
                    this.bitField0_ &= -17;
                    return this;
                }

                public TopDetail clearCode() {
                    this.code_ = "";
                    this.bitField0_ &= -3;
                    return this;
                }

                public TopDetail clearExchange() {
                    this.exchange_ = 0;
                    this.bitField0_ &= -9;
                    return this;
                }

                public TopDetail clearId() {
                    this.id_ = 0;
                    this.bitField0_ &= -2;
                    return this;
                }

                public TopDetail clearName() {
                    this.name_ = "";
                    this.bitField0_ &= -5;
                    return this;
                }

                public TopDetail clearRatio() {
                    this.ratio_ = 0;
                    this.bitField0_ &= -129;
                    return this;
                }

                public TopDetail clearSession() {
                    this.session_ = 0;
                    this.bitField0_ &= -33;
                    return this;
                }

                public TopDetail clearValue() {
                    this.value_ = 0;
                    this.bitField0_ &= -65;
                    return this;
                }

                /* access modifiers changed from: protected */
                public int computeSerializedSize() {
                    int computeSerializedSize = super.computeSerializedSize();
                    if ((this.bitField0_ & 1) != 0) {
                        computeSerializedSize += CodedOutputByteBufferNano.computeUInt32Size(1, this.id_);
                    }
                    if ((this.bitField0_ & 2) != 0) {
                        computeSerializedSize += CodedOutputByteBufferNano.computeStringSize(2, this.code_);
                    }
                    if ((this.bitField0_ & 4) != 0) {
                        computeSerializedSize += CodedOutputByteBufferNano.computeStringSize(3, this.name_);
                    }
                    if ((this.bitField0_ & 8) != 0) {
                        computeSerializedSize += CodedOutputByteBufferNano.computeUInt32Size(4, this.exchange_);
                    }
                    if ((this.bitField0_ & 16) != 0) {
                        computeSerializedSize += CodedOutputByteBufferNano.computeUInt64Size(5, this.category_);
                    }
                    if ((this.bitField0_ & 32) != 0) {
                        computeSerializedSize += CodedOutputByteBufferNano.computeUInt32Size(6, this.session_);
                    }
                    if ((this.bitField0_ & 64) != 0) {
                        computeSerializedSize += CodedOutputByteBufferNano.computeInt64Size(7, this.value_);
                    }
                    if ((this.bitField0_ & 128) != 0) {
                        return computeSerializedSize + CodedOutputByteBufferNano.computeInt32Size(8, this.ratio_);
                    }
                    return computeSerializedSize;
                }

                public long getCategory() {
                    return this.category_;
                }

                public String getCode() {
                    return this.code_;
                }

                public int getExchange() {
                    return this.exchange_;
                }

                public int getId() {
                    return this.id_;
                }

                public String getName() {
                    return this.name_;
                }

                public int getRatio() {
                    return this.ratio_;
                }

                public int getSession() {
                    return this.session_;
                }

                public long getValue() {
                    return this.value_;
                }

                public boolean hasCategory() {
                    if ((this.bitField0_ & 16) != 0) {
                        return true;
                    }
                    return false;
                }

                public boolean hasCode() {
                    if ((this.bitField0_ & 2) != 0) {
                        return true;
                    }
                    return false;
                }

                public boolean hasExchange() {
                    if ((this.bitField0_ & 8) != 0) {
                        return true;
                    }
                    return false;
                }

                public boolean hasId() {
                    if ((this.bitField0_ & 1) != 0) {
                        return true;
                    }
                    return false;
                }

                public boolean hasName() {
                    if ((this.bitField0_ & 4) != 0) {
                        return true;
                    }
                    return false;
                }

                public boolean hasRatio() {
                    if ((this.bitField0_ & 128) != 0) {
                        return true;
                    }
                    return false;
                }

                public boolean hasSession() {
                    if ((this.bitField0_ & 32) != 0) {
                        return true;
                    }
                    return false;
                }

                public boolean hasValue() {
                    if ((this.bitField0_ & 64) != 0) {
                        return true;
                    }
                    return false;
                }

                public TopDetail setCategory(long j10) {
                    this.category_ = j10;
                    this.bitField0_ |= 16;
                    return this;
                }

                public TopDetail setCode(String str) {
                    str.getClass();
                    this.code_ = str;
                    this.bitField0_ |= 2;
                    return this;
                }

                public TopDetail setExchange(int i10) {
                    this.exchange_ = i10;
                    this.bitField0_ |= 8;
                    return this;
                }

                public TopDetail setId(int i10) {
                    this.id_ = i10;
                    this.bitField0_ |= 1;
                    return this;
                }

                public TopDetail setName(String str) {
                    str.getClass();
                    this.name_ = str;
                    this.bitField0_ |= 4;
                    return this;
                }

                public TopDetail setRatio(int i10) {
                    this.ratio_ = i10;
                    this.bitField0_ |= 128;
                    return this;
                }

                public TopDetail setSession(int i10) {
                    this.session_ = i10;
                    this.bitField0_ |= 32;
                    return this;
                }

                public TopDetail setValue(long j10) {
                    this.value_ = j10;
                    this.bitField0_ |= 64;
                    return this;
                }

                public void writeTo(CodedOutputByteBufferNano codedOutputByteBufferNano) throws IOException {
                    if ((this.bitField0_ & 1) != 0) {
                        codedOutputByteBufferNano.writeUInt32(1, this.id_);
                    }
                    if ((this.bitField0_ & 2) != 0) {
                        codedOutputByteBufferNano.writeString(2, this.code_);
                    }
                    if ((this.bitField0_ & 4) != 0) {
                        codedOutputByteBufferNano.writeString(3, this.name_);
                    }
                    if ((this.bitField0_ & 8) != 0) {
                        codedOutputByteBufferNano.writeUInt32(4, this.exchange_);
                    }
                    if ((this.bitField0_ & 16) != 0) {
                        codedOutputByteBufferNano.writeUInt64(5, this.category_);
                    }
                    if ((this.bitField0_ & 32) != 0) {
                        codedOutputByteBufferNano.writeUInt32(6, this.session_);
                    }
                    if ((this.bitField0_ & 64) != 0) {
                        codedOutputByteBufferNano.writeInt64(7, this.value_);
                    }
                    if ((this.bitField0_ & 128) != 0) {
                        codedOutputByteBufferNano.writeInt32(8, this.ratio_);
                    }
                    super.writeTo(codedOutputByteBufferNano);
                }

                public static TopDetail parseFrom(CodedInputByteBufferNano codedInputByteBufferNano) throws IOException {
                    return new TopDetail().mergeFrom(codedInputByteBufferNano);
                }

                public TopDetail mergeFrom(CodedInputByteBufferNano codedInputByteBufferNano) throws IOException {
                    while (true) {
                        int readTag = codedInputByteBufferNano.readTag();
                        if (readTag == 0) {
                            return this;
                        }
                        if (readTag == 8) {
                            this.id_ = codedInputByteBufferNano.readUInt32();
                            this.bitField0_ |= 1;
                        } else if (readTag == 18) {
                            this.code_ = codedInputByteBufferNano.readString();
                            this.bitField0_ |= 2;
                        } else if (readTag == 26) {
                            this.name_ = codedInputByteBufferNano.readString();
                            this.bitField0_ |= 4;
                        } else if (readTag == 32) {
                            this.exchange_ = codedInputByteBufferNano.readUInt32();
                            this.bitField0_ |= 8;
                        } else if (readTag == 40) {
                            this.category_ = codedInputByteBufferNano.readUInt64();
                            this.bitField0_ |= 16;
                        } else if (readTag == 48) {
                            this.session_ = codedInputByteBufferNano.readUInt32();
                            this.bitField0_ |= 32;
                        } else if (readTag == 56) {
                            this.value_ = codedInputByteBufferNano.readInt64();
                            this.bitField0_ |= 64;
                        } else if (readTag == 64) {
                            this.ratio_ = codedInputByteBufferNano.readInt32();
                            this.bitField0_ |= 128;
                        } else if (!WireFormatNano.parseUnknownField(codedInputByteBufferNano, readTag)) {
                            return this;
                        }
                    }
                }
            }

            public TopShareData() {
                clear();
            }

            public static TopShareData[] emptyArray() {
                if (_emptyArray == null) {
                    synchronized (InternalNano.LAZY_INIT_LOCK) {
                        try {
                            if (_emptyArray == null) {
                                _emptyArray = new TopShareData[0];
                            }
                        } catch (Throwable th) {
                            throw th;
                        }
                    }
                }
                return _emptyArray;
            }

            public static TopShareData parseFrom(byte[] bArr) throws InvalidProtocolBufferNanoException {
                return (TopShareData) MessageNano.mergeFrom(new TopShareData(), bArr);
            }

            public TopShareData clear() {
                this.bitField0_ = 0;
                this.list = TopDetail.emptyArray();
                this.date_ = 0;
                this.calendarDate = WireFormatNano.EMPTY_INT_ARRAY;
                this.cachedSize = -1;
                return this;
            }

            public TopShareData clearDate() {
                this.date_ = 0;
                this.bitField0_ &= -2;
                return this;
            }

            /* access modifiers changed from: protected */
            public int computeSerializedSize() {
                int computeSerializedSize = super.computeSerializedSize();
                TopDetail[] topDetailArr = this.list;
                int i10 = 0;
                if (topDetailArr != null && topDetailArr.length > 0) {
                    int i11 = 0;
                    while (true) {
                        TopDetail[] topDetailArr2 = this.list;
                        if (i11 >= topDetailArr2.length) {
                            break;
                        }
                        TopDetail topDetail = topDetailArr2[i11];
                        if (topDetail != null) {
                            computeSerializedSize += CodedOutputByteBufferNano.computeMessageSize(1, topDetail);
                        }
                        i11++;
                    }
                }
                if ((this.bitField0_ & 1) != 0) {
                    computeSerializedSize += CodedOutputByteBufferNano.computeUInt32Size(2, this.date_);
                }
                int[] iArr = this.calendarDate;
                if (iArr == null || iArr.length <= 0) {
                    return computeSerializedSize;
                }
                int i12 = 0;
                while (true) {
                    int[] iArr2 = this.calendarDate;
                    if (i10 >= iArr2.length) {
                        return computeSerializedSize + i12 + iArr2.length;
                    }
                    i12 += CodedOutputByteBufferNano.computeUInt32SizeNoTag(iArr2[i10]);
                    i10++;
                }
            }

            public int getDate() {
                return this.date_;
            }

            public boolean hasDate() {
                if ((this.bitField0_ & 1) != 0) {
                    return true;
                }
                return false;
            }

            public TopShareData setDate(int i10) {
                this.date_ = i10;
                this.bitField0_ |= 1;
                return this;
            }

            public void writeTo(CodedOutputByteBufferNano codedOutputByteBufferNano) throws IOException {
                TopDetail[] topDetailArr = this.list;
                int i10 = 0;
                if (topDetailArr != null && topDetailArr.length > 0) {
                    int i11 = 0;
                    while (true) {
                        TopDetail[] topDetailArr2 = this.list;
                        if (i11 >= topDetailArr2.length) {
                            break;
                        }
                        TopDetail topDetail = topDetailArr2[i11];
                        if (topDetail != null) {
                            codedOutputByteBufferNano.writeMessage(1, topDetail);
                        }
                        i11++;
                    }
                }
                if ((this.bitField0_ & 1) != 0) {
                    codedOutputByteBufferNano.writeUInt32(2, this.date_);
                }
                int[] iArr = this.calendarDate;
                if (iArr != null && iArr.length > 0) {
                    while (true) {
                        int[] iArr2 = this.calendarDate;
                        if (i10 >= iArr2.length) {
                            break;
                        }
                        codedOutputByteBufferNano.writeUInt32(3, iArr2[i10]);
                        i10++;
                    }
                }
                super.writeTo(codedOutputByteBufferNano);
            }

            public static TopShareData parseFrom(CodedInputByteBufferNano codedInputByteBufferNano) throws IOException {
                return new TopShareData().mergeFrom(codedInputByteBufferNano);
            }

            public TopShareData mergeFrom(CodedInputByteBufferNano codedInputByteBufferNano) throws IOException {
                while (true) {
                    int readTag = codedInputByteBufferNano.readTag();
                    if (readTag == 0) {
                        return this;
                    }
                    if (readTag == 10) {
                        int repeatedFieldArrayLength = WireFormatNano.getRepeatedFieldArrayLength(codedInputByteBufferNano, 10);
                        TopDetail[] topDetailArr = this.list;
                        int length = topDetailArr == null ? 0 : topDetailArr.length;
                        int i10 = repeatedFieldArrayLength + length;
                        TopDetail[] topDetailArr2 = new TopDetail[i10];
                        if (length != 0) {
                            System.arraycopy(topDetailArr, 0, topDetailArr2, 0, length);
                        }
                        while (length < i10 - 1) {
                            TopDetail topDetail = new TopDetail();
                            topDetailArr2[length] = topDetail;
                            codedInputByteBufferNano.readMessage(topDetail);
                            codedInputByteBufferNano.readTag();
                            length++;
                        }
                        TopDetail topDetail2 = new TopDetail();
                        topDetailArr2[length] = topDetail2;
                        codedInputByteBufferNano.readMessage(topDetail2);
                        this.list = topDetailArr2;
                    } else if (readTag == 16) {
                        this.date_ = codedInputByteBufferNano.readUInt32();
                        this.bitField0_ |= 1;
                    } else if (readTag == 24) {
                        int repeatedFieldArrayLength2 = WireFormatNano.getRepeatedFieldArrayLength(codedInputByteBufferNano, 24);
                        int[] iArr = this.calendarDate;
                        int length2 = iArr == null ? 0 : iArr.length;
                        int i11 = repeatedFieldArrayLength2 + length2;
                        int[] iArr2 = new int[i11];
                        if (length2 != 0) {
                            System.arraycopy(iArr, 0, iArr2, 0, length2);
                        }
                        while (length2 < i11 - 1) {
                            iArr2[length2] = codedInputByteBufferNano.readUInt32();
                            codedInputByteBufferNano.readTag();
                            length2++;
                        }
                        iArr2[length2] = codedInputByteBufferNano.readUInt32();
                        this.calendarDate = iArr2;
                    } else if (readTag == 26) {
                        int pushLimit = codedInputByteBufferNano.pushLimit(codedInputByteBufferNano.readRawVarint32());
                        int position = codedInputByteBufferNano.getPosition();
                        int i12 = 0;
                        while (codedInputByteBufferNano.getBytesUntilLimit() > 0) {
                            codedInputByteBufferNano.readUInt32();
                            i12++;
                        }
                        codedInputByteBufferNano.rewindToPosition(position);
                        int[] iArr3 = this.calendarDate;
                        int length3 = iArr3 == null ? 0 : iArr3.length;
                        int i13 = i12 + length3;
                        int[] iArr4 = new int[i13];
                        if (length3 != 0) {
                            System.arraycopy(iArr3, 0, iArr4, 0, length3);
                        }
                        while (length3 < i13) {
                            iArr4[length3] = codedInputByteBufferNano.readUInt32();
                            length3++;
                        }
                        this.calendarDate = iArr4;
                        codedInputByteBufferNano.popLimit(pushLimit);
                    } else if (!WireFormatNano.parseUnknownField(codedInputByteBufferNano, readTag)) {
                        return this;
                    }
                }
            }
        }

        public TopShare_Response() {
            clear();
        }

        public static TopShare_Response[] emptyArray() {
            if (_emptyArray == null) {
                synchronized (InternalNano.LAZY_INIT_LOCK) {
                    try {
                        if (_emptyArray == null) {
                            _emptyArray = new TopShare_Response[0];
                        }
                    } catch (Throwable th) {
                        throw th;
                    }
                }
            }
            return _emptyArray;
        }

        public static TopShare_Response parseFrom(byte[] bArr) throws InvalidProtocolBufferNanoException {
            return (TopShare_Response) MessageNano.mergeFrom(new TopShare_Response(), bArr);
        }

        public TopShare_Response clear() {
            this.input = null;
            this.output = null;
            this.cachedSize = -1;
            return this;
        }

        /* access modifiers changed from: protected */
        public int computeSerializedSize() {
            int computeSerializedSize = super.computeSerializedSize();
            TopShareRequest.TopShare_Request topShare_Request = this.input;
            if (topShare_Request != null) {
                computeSerializedSize += CodedOutputByteBufferNano.computeMessageSize(1, topShare_Request);
            }
            TopShareData topShareData = this.output;
            if (topShareData != null) {
                return computeSerializedSize + CodedOutputByteBufferNano.computeMessageSize(2, topShareData);
            }
            return computeSerializedSize;
        }

        public void writeTo(CodedOutputByteBufferNano codedOutputByteBufferNano) throws IOException {
            TopShareRequest.TopShare_Request topShare_Request = this.input;
            if (topShare_Request != null) {
                codedOutputByteBufferNano.writeMessage(1, topShare_Request);
            }
            TopShareData topShareData = this.output;
            if (topShareData != null) {
                codedOutputByteBufferNano.writeMessage(2, topShareData);
            }
            super.writeTo(codedOutputByteBufferNano);
        }

        public static TopShare_Response parseFrom(CodedInputByteBufferNano codedInputByteBufferNano) throws IOException {
            return new TopShare_Response().mergeFrom(codedInputByteBufferNano);
        }

        public TopShare_Response mergeFrom(CodedInputByteBufferNano codedInputByteBufferNano) throws IOException {
            while (true) {
                int readTag = codedInputByteBufferNano.readTag();
                if (readTag == 0) {
                    return this;
                }
                if (readTag == 10) {
                    if (this.input == null) {
                        this.input = new TopShareRequest.TopShare_Request();
                    }
                    codedInputByteBufferNano.readMessage(this.input);
                } else if (readTag == 18) {
                    if (this.output == null) {
                        this.output = new TopShareData();
                    }
                    codedInputByteBufferNano.readMessage(this.output);
                } else if (!WireFormatNano.parseUnknownField(codedInputByteBufferNano, readTag)) {
                    return this;
                }
            }
        }
    }
}
