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.PriceDoExRightsRequest;

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

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

        private static volatile PriceDoExRights_Response[] _emptyArray;

        public GoodsDatePriceExRights[] goodsList;

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

            private static volatile GoodsDatePriceExRights[] _emptyArray;

            private int bitField0_;

            public PriceDoExRightsRequest.PriceDoExRights_Request.GoodsDatePrice requestData;

            private int responsePrice_;

            public GoodsDatePriceExRights() {
                clear();
            }

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

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

            public GoodsDatePriceExRights clear() {
                this.bitField0_ = 0;
                this.requestData = null;
                this.responsePrice_ = 0;
                this.cachedSize = -1;
                return this;
            }

            public GoodsDatePriceExRights clearResponsePrice() {
                this.responsePrice_ = 0;
                this.bitField0_ &= -2;
                return this;
            }

            /* access modifiers changed from: protected */
            public int computeSerializedSize() {
                int computeSerializedSize = super.computeSerializedSize();
                PriceDoExRightsRequest.PriceDoExRights_Request.GoodsDatePrice goodsDatePrice = this.requestData;
                if (goodsDatePrice != null) {
                    computeSerializedSize += CodedOutputByteBufferNano.computeMessageSize(1, goodsDatePrice);
                }
                if ((this.bitField0_ & 1) != 0) {
                    return computeSerializedSize + CodedOutputByteBufferNano.computeUInt32Size(2, this.responsePrice_);
                }
                return computeSerializedSize;
            }

            public int getResponsePrice() {
                return this.responsePrice_;
            }

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

            public GoodsDatePriceExRights setResponsePrice(int i10) {
                this.responsePrice_ = i10;
                this.bitField0_ |= 1;
                return this;
            }

            public void writeTo(CodedOutputByteBufferNano codedOutputByteBufferNano) throws IOException {
                PriceDoExRightsRequest.PriceDoExRights_Request.GoodsDatePrice goodsDatePrice = this.requestData;
                if (goodsDatePrice != null) {
                    codedOutputByteBufferNano.writeMessage(1, goodsDatePrice);
                }
                if ((this.bitField0_ & 1) != 0) {
                    codedOutputByteBufferNano.writeUInt32(2, this.responsePrice_);
                }
                super.writeTo(codedOutputByteBufferNano);
            }

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

            public GoodsDatePriceExRights mergeFrom(CodedInputByteBufferNano codedInputByteBufferNano) throws IOException {
                while (true) {
                    int readTag = codedInputByteBufferNano.readTag();
                    if (readTag == 0) {
                        return this;
                    }
                    if (readTag == 10) {
                        if (this.requestData == null) {
                            this.requestData = new PriceDoExRightsRequest.PriceDoExRights_Request.GoodsDatePrice();
                        }
                        codedInputByteBufferNano.readMessage(this.requestData);
                    } else if (readTag == 16) {
                        this.responsePrice_ = codedInputByteBufferNano.readUInt32();
                        this.bitField0_ |= 1;
                    } else if (!WireFormatNano.parseUnknownField(codedInputByteBufferNano, readTag)) {
                        return this;
                    }
                }
            }
        }

        public PriceDoExRights_Response() {
            clear();
        }

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

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

        public PriceDoExRights_Response clear() {
            this.goodsList = GoodsDatePriceExRights.emptyArray();
            this.cachedSize = -1;
            return this;
        }

        /* access modifiers changed from: protected */
        public int computeSerializedSize() {
            int computeSerializedSize = super.computeSerializedSize();
            GoodsDatePriceExRights[] goodsDatePriceExRightsArr = this.goodsList;
            if (goodsDatePriceExRightsArr != null && goodsDatePriceExRightsArr.length > 0) {
                int i10 = 0;
                while (true) {
                    GoodsDatePriceExRights[] goodsDatePriceExRightsArr2 = this.goodsList;
                    if (i10 >= goodsDatePriceExRightsArr2.length) {
                        break;
                    }
                    GoodsDatePriceExRights goodsDatePriceExRights = goodsDatePriceExRightsArr2[i10];
                    if (goodsDatePriceExRights != null) {
                        computeSerializedSize += CodedOutputByteBufferNano.computeMessageSize(1, goodsDatePriceExRights);
                    }
                    i10++;
                }
            }
            return computeSerializedSize;
        }

        public void writeTo(CodedOutputByteBufferNano codedOutputByteBufferNano) throws IOException {
            GoodsDatePriceExRights[] goodsDatePriceExRightsArr = this.goodsList;
            if (goodsDatePriceExRightsArr != null && goodsDatePriceExRightsArr.length > 0) {
                int i10 = 0;
                while (true) {
                    GoodsDatePriceExRights[] goodsDatePriceExRightsArr2 = this.goodsList;
                    if (i10 >= goodsDatePriceExRightsArr2.length) {
                        break;
                    }
                    GoodsDatePriceExRights goodsDatePriceExRights = goodsDatePriceExRightsArr2[i10];
                    if (goodsDatePriceExRights != null) {
                        codedOutputByteBufferNano.writeMessage(1, goodsDatePriceExRights);
                    }
                    i10++;
                }
            }
            super.writeTo(codedOutputByteBufferNano);
        }

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

        public PriceDoExRights_Response 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);
                    GoodsDatePriceExRights[] goodsDatePriceExRightsArr = this.goodsList;
                    int length = goodsDatePriceExRightsArr == null ? 0 : goodsDatePriceExRightsArr.length;
                    int i10 = repeatedFieldArrayLength + length;
                    GoodsDatePriceExRights[] goodsDatePriceExRightsArr2 = new GoodsDatePriceExRights[i10];
                    if (length != 0) {
                        System.arraycopy(goodsDatePriceExRightsArr, 0, goodsDatePriceExRightsArr2, 0, length);
                    }
                    while (length < i10 - 1) {
                        GoodsDatePriceExRights goodsDatePriceExRights = new GoodsDatePriceExRights();
                        goodsDatePriceExRightsArr2[length] = goodsDatePriceExRights;
                        codedInputByteBufferNano.readMessage(goodsDatePriceExRights);
                        codedInputByteBufferNano.readTag();
                        length++;
                    }
                    GoodsDatePriceExRights goodsDatePriceExRights2 = new GoodsDatePriceExRights();
                    goodsDatePriceExRightsArr2[length] = goodsDatePriceExRights2;
                    codedInputByteBufferNano.readMessage(goodsDatePriceExRights2);
                    this.goodsList = goodsDatePriceExRightsArr2;
                } else if (!WireFormatNano.parseUnknownField(codedInputByteBufferNano, readTag)) {
                    return this;
                }
            }
        }
    }
}
