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 MarginSecuritiesRankDetailRequest {

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

        private static volatile MarginSecuritiesRankDetail_Request[] _emptyArray;

        private int bitField0_;

        public BusinessType businessTypeInfo;

        private int date_;

        public Sort sort;

        private int top_;

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

            private static volatile BusinessType[] _emptyArray;

            private int bitField0_;

            private int dataType_;

            private int stockType_;

            public BusinessType() {
                clear();
            }

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

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

            public BusinessType clear() {
                this.bitField0_ = 0;
                this.stockType_ = 0;
                this.dataType_ = 0;
                this.cachedSize = -1;
                return this;
            }

            public BusinessType clearDataType() {
                this.dataType_ = 0;
                this.bitField0_ &= -3;
                return this;
            }

            public BusinessType clearStockType() {
                this.stockType_ = 0;
                this.bitField0_ &= -2;
                return this;
            }

            /* access modifiers changed from: protected */
            public int computeSerializedSize() {
                int computeSerializedSize = super.computeSerializedSize();
                if ((this.bitField0_ & 1) != 0) {
                    computeSerializedSize += CodedOutputByteBufferNano.computeInt32Size(1, this.stockType_);
                }
                if ((this.bitField0_ & 2) != 0) {
                    return computeSerializedSize + CodedOutputByteBufferNano.computeInt32Size(2, this.dataType_);
                }
                return computeSerializedSize;
            }

            public int getDataType() {
                return this.dataType_;
            }

            public int getStockType() {
                return this.stockType_;
            }

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

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

            public BusinessType setDataType(int i10) {
                this.dataType_ = i10;
                this.bitField0_ |= 2;
                return this;
            }

            public BusinessType setStockType(int i10) {
                this.stockType_ = i10;
                this.bitField0_ |= 1;
                return this;
            }

            public void writeTo(CodedOutputByteBufferNano codedOutputByteBufferNano) throws IOException {
                if ((this.bitField0_ & 1) != 0) {
                    codedOutputByteBufferNano.writeInt32(1, this.stockType_);
                }
                if ((this.bitField0_ & 2) != 0) {
                    codedOutputByteBufferNano.writeInt32(2, this.dataType_);
                }
                super.writeTo(codedOutputByteBufferNano);
            }

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

            public BusinessType mergeFrom(CodedInputByteBufferNano codedInputByteBufferNano) throws IOException {
                while (true) {
                    int readTag = codedInputByteBufferNano.readTag();
                    if (readTag == 0) {
                        return this;
                    }
                    if (readTag == 8) {
                        this.stockType_ = codedInputByteBufferNano.readInt32();
                        this.bitField0_ |= 1;
                    } else if (readTag == 16) {
                        this.dataType_ = codedInputByteBufferNano.readInt32();
                        this.bitField0_ |= 2;
                    } else if (!WireFormatNano.parseUnknownField(codedInputByteBufferNano, readTag)) {
                        return this;
                    }
                }
            }
        }

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

            private static volatile Sort[] _emptyArray;

            private int bitField0_;

            private boolean sortByDesc_;

            private int sortFieldId_;

            public Sort() {
                clear();
            }

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

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

            public Sort clear() {
                this.bitField0_ = 0;
                this.sortFieldId_ = 0;
                this.sortByDesc_ = false;
                this.cachedSize = -1;
                return this;
            }

            public Sort clearSortByDesc() {
                this.sortByDesc_ = false;
                this.bitField0_ &= -3;
                return this;
            }

            public Sort clearSortFieldId() {
                this.sortFieldId_ = 0;
                this.bitField0_ &= -2;
                return this;
            }

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

            public boolean getSortByDesc() {
                return this.sortByDesc_;
            }

            public int getSortFieldId() {
                return this.sortFieldId_;
            }

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

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

            public Sort setSortByDesc(boolean z9) {
                this.sortByDesc_ = z9;
                this.bitField0_ |= 2;
                return this;
            }

            public Sort setSortFieldId(int i10) {
                this.sortFieldId_ = i10;
                this.bitField0_ |= 1;
                return this;
            }

            public void writeTo(CodedOutputByteBufferNano codedOutputByteBufferNano) throws IOException {
                if ((this.bitField0_ & 1) != 0) {
                    codedOutputByteBufferNano.writeUInt32(1, this.sortFieldId_);
                }
                if ((this.bitField0_ & 2) != 0) {
                    codedOutputByteBufferNano.writeBool(2, this.sortByDesc_);
                }
                super.writeTo(codedOutputByteBufferNano);
            }

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

            public Sort mergeFrom(CodedInputByteBufferNano codedInputByteBufferNano) throws IOException {
                while (true) {
                    int readTag = codedInputByteBufferNano.readTag();
                    if (readTag == 0) {
                        return this;
                    }
                    if (readTag == 8) {
                        this.sortFieldId_ = codedInputByteBufferNano.readUInt32();
                        this.bitField0_ |= 1;
                    } else if (readTag == 16) {
                        this.sortByDesc_ = codedInputByteBufferNano.readBool();
                        this.bitField0_ |= 2;
                    } else if (!WireFormatNano.parseUnknownField(codedInputByteBufferNano, readTag)) {
                        return this;
                    }
                }
            }
        }

        public MarginSecuritiesRankDetail_Request() {
            clear();
        }

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

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

        public MarginSecuritiesRankDetail_Request clear() {
            this.bitField0_ = 0;
            this.businessTypeInfo = null;
            this.date_ = 0;
            this.top_ = 0;
            this.sort = null;
            this.cachedSize = -1;
            return this;
        }

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

        public MarginSecuritiesRankDetail_Request clearTop() {
            this.top_ = 0;
            this.bitField0_ &= -3;
            return this;
        }

        /* access modifiers changed from: protected */
        public int computeSerializedSize() {
            int computeSerializedSize = super.computeSerializedSize();
            BusinessType businessType = this.businessTypeInfo;
            if (businessType != null) {
                computeSerializedSize += CodedOutputByteBufferNano.computeMessageSize(1, businessType);
            }
            if ((this.bitField0_ & 1) != 0) {
                computeSerializedSize += CodedOutputByteBufferNano.computeUInt32Size(2, this.date_);
            }
            if ((this.bitField0_ & 2) != 0) {
                computeSerializedSize += CodedOutputByteBufferNano.computeUInt32Size(3, this.top_);
            }
            Sort sort2 = this.sort;
            if (sort2 != null) {
                return computeSerializedSize + CodedOutputByteBufferNano.computeMessageSize(4, sort2);
            }
            return computeSerializedSize;
        }

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

        public int getTop() {
            return this.top_;
        }

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

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

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

        public MarginSecuritiesRankDetail_Request setTop(int i10) {
            this.top_ = i10;
            this.bitField0_ |= 2;
            return this;
        }

        public void writeTo(CodedOutputByteBufferNano codedOutputByteBufferNano) throws IOException {
            BusinessType businessType = this.businessTypeInfo;
            if (businessType != null) {
                codedOutputByteBufferNano.writeMessage(1, businessType);
            }
            if ((this.bitField0_ & 1) != 0) {
                codedOutputByteBufferNano.writeUInt32(2, this.date_);
            }
            if ((this.bitField0_ & 2) != 0) {
                codedOutputByteBufferNano.writeUInt32(3, this.top_);
            }
            Sort sort2 = this.sort;
            if (sort2 != null) {
                codedOutputByteBufferNano.writeMessage(4, sort2);
            }
            super.writeTo(codedOutputByteBufferNano);
        }

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

        public MarginSecuritiesRankDetail_Request mergeFrom(CodedInputByteBufferNano codedInputByteBufferNano) throws IOException {
            while (true) {
                int readTag = codedInputByteBufferNano.readTag();
                if (readTag == 0) {
                    return this;
                }
                if (readTag == 10) {
                    if (this.businessTypeInfo == null) {
                        this.businessTypeInfo = new BusinessType();
                    }
                    codedInputByteBufferNano.readMessage(this.businessTypeInfo);
                } else if (readTag == 16) {
                    this.date_ = codedInputByteBufferNano.readUInt32();
                    this.bitField0_ |= 1;
                } else if (readTag == 24) {
                    this.top_ = codedInputByteBufferNano.readUInt32();
                    this.bitField0_ |= 2;
                } else if (readTag == 34) {
                    if (this.sort == null) {
                        this.sort = new Sort();
                    }
                    codedInputByteBufferNano.readMessage(this.sort);
                } else if (!WireFormatNano.parseUnknownField(codedInputByteBufferNano, readTag)) {
                    return this;
                }
            }
        }
    }
}
