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.MarginSecuritiesCommon;
import nano.MarginSecuritiesRankDetailRequest;

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

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

        private static volatile MarginSecuritiesRankDetail_Response[] _emptyArray;

        public BalanceGrowth[] balanceGrowth;

        private int bitField0_;

        private int lastUpdated_;

        public MarginSecuritiesBalance[] marginSecuritiesBalance;

        public MarginTradingNetBuying[] marginTradingNetBuying;

        public MarginSecuritiesRankDetailRequest.MarginSecuritiesRankDetail_Request request;

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

            private static volatile BalanceGrowth[] _emptyArray;

            private long balanceOfGrowth_;

            private long balanceOfMarginSecurities_;

            private int bitField0_;

            public MarginSecuritiesCommon.StockInfo stockInfo;

            public BalanceGrowth() {
                clear();
            }

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

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

            public BalanceGrowth clear() {
                this.bitField0_ = 0;
                this.stockInfo = null;
                this.balanceOfMarginSecurities_ = 0;
                this.balanceOfGrowth_ = 0;
                this.cachedSize = -1;
                return this;
            }

            public BalanceGrowth clearBalanceOfGrowth() {
                this.balanceOfGrowth_ = 0;
                this.bitField0_ &= -3;
                return this;
            }

            public BalanceGrowth clearBalanceOfMarginSecurities() {
                this.balanceOfMarginSecurities_ = 0;
                this.bitField0_ &= -2;
                return this;
            }

            /* access modifiers changed from: protected */
            public int computeSerializedSize() {
                int computeSerializedSize = super.computeSerializedSize();
                MarginSecuritiesCommon.StockInfo stockInfo2 = this.stockInfo;
                if (stockInfo2 != null) {
                    computeSerializedSize += CodedOutputByteBufferNano.computeMessageSize(1, stockInfo2);
                }
                if ((this.bitField0_ & 1) != 0) {
                    computeSerializedSize += CodedOutputByteBufferNano.computeInt64Size(2, this.balanceOfMarginSecurities_);
                }
                if ((this.bitField0_ & 2) != 0) {
                    return computeSerializedSize + CodedOutputByteBufferNano.computeInt64Size(3, this.balanceOfGrowth_);
                }
                return computeSerializedSize;
            }

            public long getBalanceOfGrowth() {
                return this.balanceOfGrowth_;
            }

            public long getBalanceOfMarginSecurities() {
                return this.balanceOfMarginSecurities_;
            }

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

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

            public BalanceGrowth setBalanceOfGrowth(long j10) {
                this.balanceOfGrowth_ = j10;
                this.bitField0_ |= 2;
                return this;
            }

            public BalanceGrowth setBalanceOfMarginSecurities(long j10) {
                this.balanceOfMarginSecurities_ = j10;
                this.bitField0_ |= 1;
                return this;
            }

            public void writeTo(CodedOutputByteBufferNano codedOutputByteBufferNano) throws IOException {
                MarginSecuritiesCommon.StockInfo stockInfo2 = this.stockInfo;
                if (stockInfo2 != null) {
                    codedOutputByteBufferNano.writeMessage(1, stockInfo2);
                }
                if ((this.bitField0_ & 1) != 0) {
                    codedOutputByteBufferNano.writeInt64(2, this.balanceOfMarginSecurities_);
                }
                if ((this.bitField0_ & 2) != 0) {
                    codedOutputByteBufferNano.writeInt64(3, this.balanceOfGrowth_);
                }
                super.writeTo(codedOutputByteBufferNano);
            }

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

            public BalanceGrowth mergeFrom(CodedInputByteBufferNano codedInputByteBufferNano) throws IOException {
                while (true) {
                    int readTag = codedInputByteBufferNano.readTag();
                    if (readTag == 0) {
                        return this;
                    }
                    if (readTag == 10) {
                        if (this.stockInfo == null) {
                            this.stockInfo = new MarginSecuritiesCommon.StockInfo();
                        }
                        codedInputByteBufferNano.readMessage(this.stockInfo);
                    } else if (readTag == 16) {
                        this.balanceOfMarginSecurities_ = codedInputByteBufferNano.readInt64();
                        this.bitField0_ |= 1;
                    } else if (readTag == 24) {
                        this.balanceOfGrowth_ = codedInputByteBufferNano.readInt64();
                        this.bitField0_ |= 2;
                    } else if (!WireFormatNano.parseUnknownField(codedInputByteBufferNano, readTag)) {
                        return this;
                    }
                }
            }
        }

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

            private static volatile MarginSecuritiesBalance[] _emptyArray;

            private long balanceOfGrowth_;

            private long balanceOfMarginSecurities_;

            private long balanceOfMargin_;

            private long balanceOfSecurities_;

            private int bitField0_;

            private int marginPercentageOfTradedMarketValue_;

            private long marginTradingBuying_;

            private long marginTradingNetBuying_;

            private long percentageOfMarginTradingNetBuying_;

            private long percentageOfTradedMarketValue_;

            private long securitiesNetSales_;

            private long securitiesPercentageOfTradedMarketValue_;

            public MarginSecuritiesCommon.StockInfo stockInfo;

            public MarginSecuritiesBalance() {
                clear();
            }

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

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

            public MarginSecuritiesBalance clear() {
                this.bitField0_ = 0;
                this.stockInfo = null;
                this.balanceOfMarginSecurities_ = 0;
                this.percentageOfTradedMarketValue_ = 0;
                this.balanceOfMargin_ = 0;
                this.marginPercentageOfTradedMarketValue_ = 0;
                this.balanceOfSecurities_ = 0;
                this.securitiesPercentageOfTradedMarketValue_ = 0;
                this.marginTradingNetBuying_ = 0;
                this.percentageOfMarginTradingNetBuying_ = 0;
                this.marginTradingBuying_ = 0;
                this.securitiesNetSales_ = 0;
                this.balanceOfGrowth_ = 0;
                this.cachedSize = -1;
                return this;
            }

            public MarginSecuritiesBalance clearBalanceOfGrowth() {
                this.balanceOfGrowth_ = 0;
                this.bitField0_ &= -1025;
                return this;
            }

            public MarginSecuritiesBalance clearBalanceOfMargin() {
                this.balanceOfMargin_ = 0;
                this.bitField0_ &= -5;
                return this;
            }

            public MarginSecuritiesBalance clearBalanceOfMarginSecurities() {
                this.balanceOfMarginSecurities_ = 0;
                this.bitField0_ &= -2;
                return this;
            }

            public MarginSecuritiesBalance clearBalanceOfSecurities() {
                this.balanceOfSecurities_ = 0;
                this.bitField0_ &= -17;
                return this;
            }

            public MarginSecuritiesBalance clearMarginPercentageOfTradedMarketValue() {
                this.marginPercentageOfTradedMarketValue_ = 0;
                this.bitField0_ &= -9;
                return this;
            }

            public MarginSecuritiesBalance clearMarginTradingBuying() {
                this.marginTradingBuying_ = 0;
                this.bitField0_ &= -257;
                return this;
            }

            public MarginSecuritiesBalance clearMarginTradingNetBuying() {
                this.marginTradingNetBuying_ = 0;
                this.bitField0_ &= -65;
                return this;
            }

            public MarginSecuritiesBalance clearPercentageOfMarginTradingNetBuying() {
                this.percentageOfMarginTradingNetBuying_ = 0;
                this.bitField0_ &= -129;
                return this;
            }

            public MarginSecuritiesBalance clearPercentageOfTradedMarketValue() {
                this.percentageOfTradedMarketValue_ = 0;
                this.bitField0_ &= -3;
                return this;
            }

            public MarginSecuritiesBalance clearSecuritiesNetSales() {
                this.securitiesNetSales_ = 0;
                this.bitField0_ &= -513;
                return this;
            }

            public MarginSecuritiesBalance clearSecuritiesPercentageOfTradedMarketValue() {
                this.securitiesPercentageOfTradedMarketValue_ = 0;
                this.bitField0_ &= -33;
                return this;
            }

            /* access modifiers changed from: protected */
            public int computeSerializedSize() {
                int computeSerializedSize = super.computeSerializedSize();
                MarginSecuritiesCommon.StockInfo stockInfo2 = this.stockInfo;
                if (stockInfo2 != null) {
                    computeSerializedSize += CodedOutputByteBufferNano.computeMessageSize(1, stockInfo2);
                }
                if ((this.bitField0_ & 1) != 0) {
                    computeSerializedSize += CodedOutputByteBufferNano.computeInt64Size(2, this.balanceOfMarginSecurities_);
                }
                if ((this.bitField0_ & 2) != 0) {
                    computeSerializedSize += CodedOutputByteBufferNano.computeInt64Size(3, this.percentageOfTradedMarketValue_);
                }
                if ((this.bitField0_ & 4) != 0) {
                    computeSerializedSize += CodedOutputByteBufferNano.computeInt64Size(4, this.balanceOfMargin_);
                }
                if ((this.bitField0_ & 8) != 0) {
                    computeSerializedSize += CodedOutputByteBufferNano.computeInt32Size(5, this.marginPercentageOfTradedMarketValue_);
                }
                if ((this.bitField0_ & 16) != 0) {
                    computeSerializedSize += CodedOutputByteBufferNano.computeInt64Size(6, this.balanceOfSecurities_);
                }
                if ((this.bitField0_ & 32) != 0) {
                    computeSerializedSize += CodedOutputByteBufferNano.computeInt64Size(7, this.securitiesPercentageOfTradedMarketValue_);
                }
                if ((this.bitField0_ & 64) != 0) {
                    computeSerializedSize += CodedOutputByteBufferNano.computeInt64Size(8, this.marginTradingNetBuying_);
                }
                if ((this.bitField0_ & 128) != 0) {
                    computeSerializedSize += CodedOutputByteBufferNano.computeInt64Size(9, this.percentageOfMarginTradingNetBuying_);
                }
                if ((this.bitField0_ & 256) != 0) {
                    computeSerializedSize += CodedOutputByteBufferNano.computeInt64Size(10, this.marginTradingBuying_);
                }
                if ((this.bitField0_ & 512) != 0) {
                    computeSerializedSize += CodedOutputByteBufferNano.computeInt64Size(11, this.securitiesNetSales_);
                }
                if ((this.bitField0_ & 1024) != 0) {
                    return computeSerializedSize + CodedOutputByteBufferNano.computeInt64Size(12, this.balanceOfGrowth_);
                }
                return computeSerializedSize;
            }

            public long getBalanceOfGrowth() {
                return this.balanceOfGrowth_;
            }

            public long getBalanceOfMargin() {
                return this.balanceOfMargin_;
            }

            public long getBalanceOfMarginSecurities() {
                return this.balanceOfMarginSecurities_;
            }

            public long getBalanceOfSecurities() {
                return this.balanceOfSecurities_;
            }

            public int getMarginPercentageOfTradedMarketValue() {
                return this.marginPercentageOfTradedMarketValue_;
            }

            public long getMarginTradingBuying() {
                return this.marginTradingBuying_;
            }

            public long getMarginTradingNetBuying() {
                return this.marginTradingNetBuying_;
            }

            public long getPercentageOfMarginTradingNetBuying() {
                return this.percentageOfMarginTradingNetBuying_;
            }

            public long getPercentageOfTradedMarketValue() {
                return this.percentageOfTradedMarketValue_;
            }

            public long getSecuritiesNetSales() {
                return this.securitiesNetSales_;
            }

            public long getSecuritiesPercentageOfTradedMarketValue() {
                return this.securitiesPercentageOfTradedMarketValue_;
            }

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

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

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

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

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

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

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

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

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

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

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

            public MarginSecuritiesBalance setBalanceOfGrowth(long j10) {
                this.balanceOfGrowth_ = j10;
                this.bitField0_ |= 1024;
                return this;
            }

            public MarginSecuritiesBalance setBalanceOfMargin(long j10) {
                this.balanceOfMargin_ = j10;
                this.bitField0_ |= 4;
                return this;
            }

            public MarginSecuritiesBalance setBalanceOfMarginSecurities(long j10) {
                this.balanceOfMarginSecurities_ = j10;
                this.bitField0_ |= 1;
                return this;
            }

            public MarginSecuritiesBalance setBalanceOfSecurities(long j10) {
                this.balanceOfSecurities_ = j10;
                this.bitField0_ |= 16;
                return this;
            }

            public MarginSecuritiesBalance setMarginPercentageOfTradedMarketValue(int i10) {
                this.marginPercentageOfTradedMarketValue_ = i10;
                this.bitField0_ |= 8;
                return this;
            }

            public MarginSecuritiesBalance setMarginTradingBuying(long j10) {
                this.marginTradingBuying_ = j10;
                this.bitField0_ |= 256;
                return this;
            }

            public MarginSecuritiesBalance setMarginTradingNetBuying(long j10) {
                this.marginTradingNetBuying_ = j10;
                this.bitField0_ |= 64;
                return this;
            }

            public MarginSecuritiesBalance setPercentageOfMarginTradingNetBuying(long j10) {
                this.percentageOfMarginTradingNetBuying_ = j10;
                this.bitField0_ |= 128;
                return this;
            }

            public MarginSecuritiesBalance setPercentageOfTradedMarketValue(long j10) {
                this.percentageOfTradedMarketValue_ = j10;
                this.bitField0_ |= 2;
                return this;
            }

            public MarginSecuritiesBalance setSecuritiesNetSales(long j10) {
                this.securitiesNetSales_ = j10;
                this.bitField0_ |= 512;
                return this;
            }

            public MarginSecuritiesBalance setSecuritiesPercentageOfTradedMarketValue(long j10) {
                this.securitiesPercentageOfTradedMarketValue_ = j10;
                this.bitField0_ |= 32;
                return this;
            }

            public void writeTo(CodedOutputByteBufferNano codedOutputByteBufferNano) throws IOException {
                MarginSecuritiesCommon.StockInfo stockInfo2 = this.stockInfo;
                if (stockInfo2 != null) {
                    codedOutputByteBufferNano.writeMessage(1, stockInfo2);
                }
                if ((this.bitField0_ & 1) != 0) {
                    codedOutputByteBufferNano.writeInt64(2, this.balanceOfMarginSecurities_);
                }
                if ((this.bitField0_ & 2) != 0) {
                    codedOutputByteBufferNano.writeInt64(3, this.percentageOfTradedMarketValue_);
                }
                if ((this.bitField0_ & 4) != 0) {
                    codedOutputByteBufferNano.writeInt64(4, this.balanceOfMargin_);
                }
                if ((this.bitField0_ & 8) != 0) {
                    codedOutputByteBufferNano.writeInt32(5, this.marginPercentageOfTradedMarketValue_);
                }
                if ((this.bitField0_ & 16) != 0) {
                    codedOutputByteBufferNano.writeInt64(6, this.balanceOfSecurities_);
                }
                if ((this.bitField0_ & 32) != 0) {
                    codedOutputByteBufferNano.writeInt64(7, this.securitiesPercentageOfTradedMarketValue_);
                }
                if ((this.bitField0_ & 64) != 0) {
                    codedOutputByteBufferNano.writeInt64(8, this.marginTradingNetBuying_);
                }
                if ((this.bitField0_ & 128) != 0) {
                    codedOutputByteBufferNano.writeInt64(9, this.percentageOfMarginTradingNetBuying_);
                }
                if ((this.bitField0_ & 256) != 0) {
                    codedOutputByteBufferNano.writeInt64(10, this.marginTradingBuying_);
                }
                if ((this.bitField0_ & 512) != 0) {
                    codedOutputByteBufferNano.writeInt64(11, this.securitiesNetSales_);
                }
                if ((this.bitField0_ & 1024) != 0) {
                    codedOutputByteBufferNano.writeInt64(12, this.balanceOfGrowth_);
                }
                super.writeTo(codedOutputByteBufferNano);
            }

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

            public MarginSecuritiesBalance mergeFrom(CodedInputByteBufferNano codedInputByteBufferNano) throws IOException {
                while (true) {
                    int readTag = codedInputByteBufferNano.readTag();
                    switch(readTag) {
                        case 0:
                            return this;
                        case 10:
                            if (this.stockInfo == null) {
                                this.stockInfo = new MarginSecuritiesCommon.StockInfo();
                            }
                            codedInputByteBufferNano.readMessage(this.stockInfo);
                            break;
                        case 16:
                            this.balanceOfMarginSecurities_ = codedInputByteBufferNano.readInt64();
                            this.bitField0_ |= 1;
                            break;
                        case 24:
                            this.percentageOfTradedMarketValue_ = codedInputByteBufferNano.readInt64();
                            this.bitField0_ |= 2;
                            break;
                        case 32:
                            this.balanceOfMargin_ = codedInputByteBufferNano.readInt64();
                            this.bitField0_ |= 4;
                            break;
                        case 40:
                            this.marginPercentageOfTradedMarketValue_ = codedInputByteBufferNano.readInt32();
                            this.bitField0_ |= 8;
                            break;
                        case 48:
                            this.balanceOfSecurities_ = codedInputByteBufferNano.readInt64();
                            this.bitField0_ |= 16;
                            break;
                        case 56:
                            this.securitiesPercentageOfTradedMarketValue_ = codedInputByteBufferNano.readInt64();
                            this.bitField0_ |= 32;
                            break;
                        case 64:
                            this.marginTradingNetBuying_ = codedInputByteBufferNano.readInt64();
                            this.bitField0_ |= 64;
                            break;
                        case 72:
                            this.percentageOfMarginTradingNetBuying_ = codedInputByteBufferNano.readInt64();
                            this.bitField0_ |= 128;
                            break;
                        case 80:
                            this.marginTradingBuying_ = codedInputByteBufferNano.readInt64();
                            this.bitField0_ |= 256;
                            break;
                        case 88:
                            this.securitiesNetSales_ = codedInputByteBufferNano.readInt64();
                            this.bitField0_ |= 512;
                            break;
                        case 96:
                            this.balanceOfGrowth_ = codedInputByteBufferNano.readInt64();
                            this.bitField0_ |= 1024;
                            break;
                        default:
                            if (WireFormatNano.parseUnknownField(codedInputByteBufferNano, readTag)) {
                                break;
                            } else {
                                return this;
                            }
                    }
                }
            }
        }

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

            private static volatile MarginTradingNetBuying[] _emptyArray;

            private int bitField0_;

            private long netBuying_;

            private long percentageOfBuying_;

            public MarginSecuritiesCommon.StockInfo stockInfo;

            public MarginTradingNetBuying() {
                clear();
            }

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

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

            public MarginTradingNetBuying clear() {
                this.bitField0_ = 0;
                this.stockInfo = null;
                this.netBuying_ = 0;
                this.percentageOfBuying_ = 0;
                this.cachedSize = -1;
                return this;
            }

            public MarginTradingNetBuying clearNetBuying() {
                this.netBuying_ = 0;
                this.bitField0_ &= -2;
                return this;
            }

            public MarginTradingNetBuying clearPercentageOfBuying() {
                this.percentageOfBuying_ = 0;
                this.bitField0_ &= -3;
                return this;
            }

            /* access modifiers changed from: protected */
            public int computeSerializedSize() {
                int computeSerializedSize = super.computeSerializedSize();
                MarginSecuritiesCommon.StockInfo stockInfo2 = this.stockInfo;
                if (stockInfo2 != null) {
                    computeSerializedSize += CodedOutputByteBufferNano.computeMessageSize(1, stockInfo2);
                }
                if ((this.bitField0_ & 1) != 0) {
                    computeSerializedSize += CodedOutputByteBufferNano.computeInt64Size(2, this.netBuying_);
                }
                if ((this.bitField0_ & 2) != 0) {
                    return computeSerializedSize + CodedOutputByteBufferNano.computeInt64Size(3, this.percentageOfBuying_);
                }
                return computeSerializedSize;
            }

            public long getNetBuying() {
                return this.netBuying_;
            }

            public long getPercentageOfBuying() {
                return this.percentageOfBuying_;
            }

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

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

            public MarginTradingNetBuying setNetBuying(long j10) {
                this.netBuying_ = j10;
                this.bitField0_ |= 1;
                return this;
            }

            public MarginTradingNetBuying setPercentageOfBuying(long j10) {
                this.percentageOfBuying_ = j10;
                this.bitField0_ |= 2;
                return this;
            }

            public void writeTo(CodedOutputByteBufferNano codedOutputByteBufferNano) throws IOException {
                MarginSecuritiesCommon.StockInfo stockInfo2 = this.stockInfo;
                if (stockInfo2 != null) {
                    codedOutputByteBufferNano.writeMessage(1, stockInfo2);
                }
                if ((this.bitField0_ & 1) != 0) {
                    codedOutputByteBufferNano.writeInt64(2, this.netBuying_);
                }
                if ((this.bitField0_ & 2) != 0) {
                    codedOutputByteBufferNano.writeInt64(3, this.percentageOfBuying_);
                }
                super.writeTo(codedOutputByteBufferNano);
            }

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

            public MarginTradingNetBuying mergeFrom(CodedInputByteBufferNano codedInputByteBufferNano) throws IOException {
                while (true) {
                    int readTag = codedInputByteBufferNano.readTag();
                    if (readTag == 0) {
                        return this;
                    }
                    if (readTag == 10) {
                        if (this.stockInfo == null) {
                            this.stockInfo = new MarginSecuritiesCommon.StockInfo();
                        }
                        codedInputByteBufferNano.readMessage(this.stockInfo);
                    } else if (readTag == 16) {
                        this.netBuying_ = codedInputByteBufferNano.readInt64();
                        this.bitField0_ |= 1;
                    } else if (readTag == 24) {
                        this.percentageOfBuying_ = codedInputByteBufferNano.readInt64();
                        this.bitField0_ |= 2;
                    } else if (!WireFormatNano.parseUnknownField(codedInputByteBufferNano, readTag)) {
                        return this;
                    }
                }
            }
        }

        public MarginSecuritiesRankDetail_Response() {
            clear();
        }

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

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

        public MarginSecuritiesRankDetail_Response clear() {
            this.bitField0_ = 0;
            this.request = null;
            this.lastUpdated_ = 0;
            this.marginTradingNetBuying = MarginTradingNetBuying.emptyArray();
            this.balanceGrowth = BalanceGrowth.emptyArray();
            this.marginSecuritiesBalance = MarginSecuritiesBalance.emptyArray();
            this.cachedSize = -1;
            return this;
        }

        public MarginSecuritiesRankDetail_Response clearLastUpdated() {
            this.lastUpdated_ = 0;
            this.bitField0_ &= -2;
            return this;
        }

        /* access modifiers changed from: protected */
        public int computeSerializedSize() {
            int computeSerializedSize = super.computeSerializedSize();
            MarginSecuritiesRankDetailRequest.MarginSecuritiesRankDetail_Request marginSecuritiesRankDetail_Request = this.request;
            if (marginSecuritiesRankDetail_Request != null) {
                computeSerializedSize += CodedOutputByteBufferNano.computeMessageSize(1, marginSecuritiesRankDetail_Request);
            }
            if ((this.bitField0_ & 1) != 0) {
                computeSerializedSize += CodedOutputByteBufferNano.computeUInt32Size(2, this.lastUpdated_);
            }
            MarginTradingNetBuying[] marginTradingNetBuyingArr = this.marginTradingNetBuying;
            int i10 = 0;
            if (marginTradingNetBuyingArr != null && marginTradingNetBuyingArr.length > 0) {
                int i11 = 0;
                while (true) {
                    MarginTradingNetBuying[] marginTradingNetBuyingArr2 = this.marginTradingNetBuying;
                    if (i11 >= marginTradingNetBuyingArr2.length) {
                        break;
                    }
                    MarginTradingNetBuying marginTradingNetBuying2 = marginTradingNetBuyingArr2[i11];
                    if (marginTradingNetBuying2 != null) {
                        computeSerializedSize += CodedOutputByteBufferNano.computeMessageSize(3, marginTradingNetBuying2);
                    }
                    i11++;
                }
            }
            BalanceGrowth[] balanceGrowthArr = this.balanceGrowth;
            if (balanceGrowthArr != null && balanceGrowthArr.length > 0) {
                int i12 = 0;
                while (true) {
                    BalanceGrowth[] balanceGrowthArr2 = this.balanceGrowth;
                    if (i12 >= balanceGrowthArr2.length) {
                        break;
                    }
                    BalanceGrowth balanceGrowth2 = balanceGrowthArr2[i12];
                    if (balanceGrowth2 != null) {
                        computeSerializedSize += CodedOutputByteBufferNano.computeMessageSize(4, balanceGrowth2);
                    }
                    i12++;
                }
            }
            MarginSecuritiesBalance[] marginSecuritiesBalanceArr = this.marginSecuritiesBalance;
            if (marginSecuritiesBalanceArr != null && marginSecuritiesBalanceArr.length > 0) {
                while (true) {
                    MarginSecuritiesBalance[] marginSecuritiesBalanceArr2 = this.marginSecuritiesBalance;
                    if (i10 >= marginSecuritiesBalanceArr2.length) {
                        break;
                    }
                    MarginSecuritiesBalance marginSecuritiesBalance2 = marginSecuritiesBalanceArr2[i10];
                    if (marginSecuritiesBalance2 != null) {
                        computeSerializedSize += CodedOutputByteBufferNano.computeMessageSize(5, marginSecuritiesBalance2);
                    }
                    i10++;
                }
            }
            return computeSerializedSize;
        }

        public int getLastUpdated() {
            return this.lastUpdated_;
        }

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

        public MarginSecuritiesRankDetail_Response setLastUpdated(int i10) {
            this.lastUpdated_ = i10;
            this.bitField0_ |= 1;
            return this;
        }

        public void writeTo(CodedOutputByteBufferNano codedOutputByteBufferNano) throws IOException {
            MarginSecuritiesRankDetailRequest.MarginSecuritiesRankDetail_Request marginSecuritiesRankDetail_Request = this.request;
            if (marginSecuritiesRankDetail_Request != null) {
                codedOutputByteBufferNano.writeMessage(1, marginSecuritiesRankDetail_Request);
            }
            if ((this.bitField0_ & 1) != 0) {
                codedOutputByteBufferNano.writeUInt32(2, this.lastUpdated_);
            }
            MarginTradingNetBuying[] marginTradingNetBuyingArr = this.marginTradingNetBuying;
            int i10 = 0;
            if (marginTradingNetBuyingArr != null && marginTradingNetBuyingArr.length > 0) {
                int i11 = 0;
                while (true) {
                    MarginTradingNetBuying[] marginTradingNetBuyingArr2 = this.marginTradingNetBuying;
                    if (i11 >= marginTradingNetBuyingArr2.length) {
                        break;
                    }
                    MarginTradingNetBuying marginTradingNetBuying2 = marginTradingNetBuyingArr2[i11];
                    if (marginTradingNetBuying2 != null) {
                        codedOutputByteBufferNano.writeMessage(3, marginTradingNetBuying2);
                    }
                    i11++;
                }
            }
            BalanceGrowth[] balanceGrowthArr = this.balanceGrowth;
            if (balanceGrowthArr != null && balanceGrowthArr.length > 0) {
                int i12 = 0;
                while (true) {
                    BalanceGrowth[] balanceGrowthArr2 = this.balanceGrowth;
                    if (i12 >= balanceGrowthArr2.length) {
                        break;
                    }
                    BalanceGrowth balanceGrowth2 = balanceGrowthArr2[i12];
                    if (balanceGrowth2 != null) {
                        codedOutputByteBufferNano.writeMessage(4, balanceGrowth2);
                    }
                    i12++;
                }
            }
            MarginSecuritiesBalance[] marginSecuritiesBalanceArr = this.marginSecuritiesBalance;
            if (marginSecuritiesBalanceArr != null && marginSecuritiesBalanceArr.length > 0) {
                while (true) {
                    MarginSecuritiesBalance[] marginSecuritiesBalanceArr2 = this.marginSecuritiesBalance;
                    if (i10 >= marginSecuritiesBalanceArr2.length) {
                        break;
                    }
                    MarginSecuritiesBalance marginSecuritiesBalance2 = marginSecuritiesBalanceArr2[i10];
                    if (marginSecuritiesBalance2 != null) {
                        codedOutputByteBufferNano.writeMessage(5, marginSecuritiesBalance2);
                    }
                    i10++;
                }
            }
            super.writeTo(codedOutputByteBufferNano);
        }

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

        public MarginSecuritiesRankDetail_Response mergeFrom(CodedInputByteBufferNano codedInputByteBufferNano) throws IOException {
            while (true) {
                int readTag = codedInputByteBufferNano.readTag();
                if (readTag == 0) {
                    return this;
                }
                if (readTag == 10) {
                    if (this.request == null) {
                        this.request = new MarginSecuritiesRankDetailRequest.MarginSecuritiesRankDetail_Request();
                    }
                    codedInputByteBufferNano.readMessage(this.request);
                } else if (readTag == 16) {
                    this.lastUpdated_ = codedInputByteBufferNano.readUInt32();
                    this.bitField0_ |= 1;
                } else if (readTag == 26) {
                    int repeatedFieldArrayLength = WireFormatNano.getRepeatedFieldArrayLength(codedInputByteBufferNano, 26);
                    MarginTradingNetBuying[] marginTradingNetBuyingArr = this.marginTradingNetBuying;
                    int length = marginTradingNetBuyingArr == null ? 0 : marginTradingNetBuyingArr.length;
                    int i10 = repeatedFieldArrayLength + length;
                    MarginTradingNetBuying[] marginTradingNetBuyingArr2 = new MarginTradingNetBuying[i10];
                    if (length != 0) {
                        System.arraycopy(marginTradingNetBuyingArr, 0, marginTradingNetBuyingArr2, 0, length);
                    }
                    while (length < i10 - 1) {
                        MarginTradingNetBuying marginTradingNetBuying2 = new MarginTradingNetBuying();
                        marginTradingNetBuyingArr2[length] = marginTradingNetBuying2;
                        codedInputByteBufferNano.readMessage(marginTradingNetBuying2);
                        codedInputByteBufferNano.readTag();
                        length++;
                    }
                    MarginTradingNetBuying marginTradingNetBuying3 = new MarginTradingNetBuying();
                    marginTradingNetBuyingArr2[length] = marginTradingNetBuying3;
                    codedInputByteBufferNano.readMessage(marginTradingNetBuying3);
                    this.marginTradingNetBuying = marginTradingNetBuyingArr2;
                } else if (readTag == 34) {
                    int repeatedFieldArrayLength2 = WireFormatNano.getRepeatedFieldArrayLength(codedInputByteBufferNano, 34);
                    BalanceGrowth[] balanceGrowthArr = this.balanceGrowth;
                    int length2 = balanceGrowthArr == null ? 0 : balanceGrowthArr.length;
                    int i11 = repeatedFieldArrayLength2 + length2;
                    BalanceGrowth[] balanceGrowthArr2 = new BalanceGrowth[i11];
                    if (length2 != 0) {
                        System.arraycopy(balanceGrowthArr, 0, balanceGrowthArr2, 0, length2);
                    }
                    while (length2 < i11 - 1) {
                        BalanceGrowth balanceGrowth2 = new BalanceGrowth();
                        balanceGrowthArr2[length2] = balanceGrowth2;
                        codedInputByteBufferNano.readMessage(balanceGrowth2);
                        codedInputByteBufferNano.readTag();
                        length2++;
                    }
                    BalanceGrowth balanceGrowth3 = new BalanceGrowth();
                    balanceGrowthArr2[length2] = balanceGrowth3;
                    codedInputByteBufferNano.readMessage(balanceGrowth3);
                    this.balanceGrowth = balanceGrowthArr2;
                } else if (readTag == 42) {
                    int repeatedFieldArrayLength3 = WireFormatNano.getRepeatedFieldArrayLength(codedInputByteBufferNano, 42);
                    MarginSecuritiesBalance[] marginSecuritiesBalanceArr = this.marginSecuritiesBalance;
                    int length3 = marginSecuritiesBalanceArr == null ? 0 : marginSecuritiesBalanceArr.length;
                    int i12 = repeatedFieldArrayLength3 + length3;
                    MarginSecuritiesBalance[] marginSecuritiesBalanceArr2 = new MarginSecuritiesBalance[i12];
                    if (length3 != 0) {
                        System.arraycopy(marginSecuritiesBalanceArr, 0, marginSecuritiesBalanceArr2, 0, length3);
                    }
                    while (length3 < i12 - 1) {
                        MarginSecuritiesBalance marginSecuritiesBalance2 = new MarginSecuritiesBalance();
                        marginSecuritiesBalanceArr2[length3] = marginSecuritiesBalance2;
                        codedInputByteBufferNano.readMessage(marginSecuritiesBalance2);
                        codedInputByteBufferNano.readTag();
                        length3++;
                    }
                    MarginSecuritiesBalance marginSecuritiesBalance3 = new MarginSecuritiesBalance();
                    marginSecuritiesBalanceArr2[length3] = marginSecuritiesBalance3;
                    codedInputByteBufferNano.readMessage(marginSecuritiesBalance3);
                    this.marginSecuritiesBalance = marginSecuritiesBalanceArr2;
                } else if (!WireFormatNano.parseUnknownField(codedInputByteBufferNano, readTag)) {
                    return this;
                }
            }
        }
    }
}
