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;

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

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

        private static volatile IndexTrend_Request[] _emptyArray;

        public TrendParam[] input;

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

            private static volatile TrendParam[] _emptyArray;

            private int bitField0_;

            private int indexId_;

            private int tradeDate_;

            private int trendTime_;

            public TrendParam() {
                clear();
            }

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

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

            public TrendParam clear() {
                this.bitField0_ = 0;
                this.indexId_ = 0;
                this.tradeDate_ = 0;
                this.trendTime_ = 0;
                this.cachedSize = -1;
                return this;
            }

            public TrendParam clearIndexId() {
                this.indexId_ = 0;
                this.bitField0_ &= -2;
                return this;
            }

            public TrendParam clearTradeDate() {
                this.tradeDate_ = 0;
                this.bitField0_ &= -3;
                return this;
            }

            public TrendParam clearTrendTime() {
                this.trendTime_ = 0;
                this.bitField0_ &= -5;
                return this;
            }

            /* access modifiers changed from: protected */
            public int computeSerializedSize() {
                int computeSerializedSize = super.computeSerializedSize();
                if ((this.bitField0_ & 1) != 0) {
                    computeSerializedSize += CodedOutputByteBufferNano.computeUInt32Size(1, this.indexId_);
                }
                if ((this.bitField0_ & 2) != 0) {
                    computeSerializedSize += CodedOutputByteBufferNano.computeUInt32Size(2, this.tradeDate_);
                }
                if ((this.bitField0_ & 4) != 0) {
                    return computeSerializedSize + CodedOutputByteBufferNano.computeUInt32Size(4, this.trendTime_);
                }
                return computeSerializedSize;
            }

            public int getIndexId() {
                return this.indexId_;
            }

            public int getTradeDate() {
                return this.tradeDate_;
            }

            public int getTrendTime() {
                return this.trendTime_;
            }

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

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

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

            public TrendParam setIndexId(int i10) {
                this.indexId_ = i10;
                this.bitField0_ |= 1;
                return this;
            }

            public TrendParam setTradeDate(int i10) {
                this.tradeDate_ = i10;
                this.bitField0_ |= 2;
                return this;
            }

            public TrendParam setTrendTime(int i10) {
                this.trendTime_ = i10;
                this.bitField0_ |= 4;
                return this;
            }

            public void writeTo(CodedOutputByteBufferNano codedOutputByteBufferNano) throws IOException {
                if ((this.bitField0_ & 1) != 0) {
                    codedOutputByteBufferNano.writeUInt32(1, this.indexId_);
                }
                if ((this.bitField0_ & 2) != 0) {
                    codedOutputByteBufferNano.writeUInt32(2, this.tradeDate_);
                }
                if ((this.bitField0_ & 4) != 0) {
                    codedOutputByteBufferNano.writeUInt32(4, this.trendTime_);
                }
                super.writeTo(codedOutputByteBufferNano);
            }

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

            public TrendParam mergeFrom(CodedInputByteBufferNano codedInputByteBufferNano) throws IOException {
                while (true) {
                    int readTag = codedInputByteBufferNano.readTag();
                    if (readTag == 0) {
                        return this;
                    }
                    if (readTag == 8) {
                        this.indexId_ = codedInputByteBufferNano.readUInt32();
                        this.bitField0_ |= 1;
                    } else if (readTag == 16) {
                        this.tradeDate_ = codedInputByteBufferNano.readUInt32();
                        this.bitField0_ |= 2;
                    } else if (readTag == 32) {
                        this.trendTime_ = codedInputByteBufferNano.readUInt32();
                        this.bitField0_ |= 4;
                    } else if (!WireFormatNano.parseUnknownField(codedInputByteBufferNano, readTag)) {
                        return this;
                    }
                }
            }
        }

        public IndexTrend_Request() {
            clear();
        }

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

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

        public IndexTrend_Request clear() {
            this.input = TrendParam.emptyArray();
            this.cachedSize = -1;
            return this;
        }

        /* access modifiers changed from: protected */
        public int computeSerializedSize() {
            int computeSerializedSize = super.computeSerializedSize();
            TrendParam[] trendParamArr = this.input;
            if (trendParamArr != null && trendParamArr.length > 0) {
                int i10 = 0;
                while (true) {
                    TrendParam[] trendParamArr2 = this.input;
                    if (i10 >= trendParamArr2.length) {
                        break;
                    }
                    TrendParam trendParam = trendParamArr2[i10];
                    if (trendParam != null) {
                        computeSerializedSize += CodedOutputByteBufferNano.computeMessageSize(1, trendParam);
                    }
                    i10++;
                }
            }
            return computeSerializedSize;
        }

        public void writeTo(CodedOutputByteBufferNano codedOutputByteBufferNano) throws IOException {
            TrendParam[] trendParamArr = this.input;
            if (trendParamArr != null && trendParamArr.length > 0) {
                int i10 = 0;
                while (true) {
                    TrendParam[] trendParamArr2 = this.input;
                    if (i10 >= trendParamArr2.length) {
                        break;
                    }
                    TrendParam trendParam = trendParamArr2[i10];
                    if (trendParam != null) {
                        codedOutputByteBufferNano.writeMessage(1, trendParam);
                    }
                    i10++;
                }
            }
            super.writeTo(codedOutputByteBufferNano);
        }

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

        public IndexTrend_Request 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);
                    TrendParam[] trendParamArr = this.input;
                    int length = trendParamArr == null ? 0 : trendParamArr.length;
                    int i10 = repeatedFieldArrayLength + length;
                    TrendParam[] trendParamArr2 = new TrendParam[i10];
                    if (length != 0) {
                        System.arraycopy(trendParamArr, 0, trendParamArr2, 0, length);
                    }
                    while (length < i10 - 1) {
                        TrendParam trendParam = new TrendParam();
                        trendParamArr2[length] = trendParam;
                        codedInputByteBufferNano.readMessage(trendParam);
                        codedInputByteBufferNano.readTag();
                        length++;
                    }
                    TrendParam trendParam2 = new TrendParam();
                    trendParamArr2[length] = trendParam2;
                    codedInputByteBufferNano.readMessage(trendParam2);
                    this.input = trendParamArr2;
                } else if (!WireFormatNano.parseUnknownField(codedInputByteBufferNano, readTag)) {
                    return this;
                }
            }
        }
    }
}
