// Generated by the protocol buffer compiler.  DO NOT EDIT!
// source: google/ads/googleads/v14/services/conversion_adjustment_upload_service.proto

package com.google.ads.googleads.v14.services;

/**
 * <pre>
 * Request message for
 * [ConversionAdjustmentUploadService.UploadConversionAdjustments][google.ads.googleads.v14.services.ConversionAdjustmentUploadService.UploadConversionAdjustments].
 * </pre>
 *
 * Protobuf type {@code google.ads.googleads.v14.services.UploadConversionAdjustmentsRequest}
 */
public final class UploadConversionAdjustmentsRequest extends
    com.google.protobuf.GeneratedMessageV3 implements
    // @@protoc_insertion_point(message_implements:google.ads.googleads.v14.services.UploadConversionAdjustmentsRequest)
    UploadConversionAdjustmentsRequestOrBuilder {
private static final long serialVersionUID = 0L;
  // Use UploadConversionAdjustmentsRequest.newBuilder() to construct.
  private UploadConversionAdjustmentsRequest(com.google.protobuf.GeneratedMessageV3.Builder<?> builder) {
    super(builder);
  }
  private UploadConversionAdjustmentsRequest() {
    customerId_ = "";
    conversionAdjustments_ = java.util.Collections.emptyList();
  }

  @java.lang.Override
  @SuppressWarnings({"unused"})
  protected java.lang.Object newInstance(
      UnusedPrivateParameter unused) {
    return new UploadConversionAdjustmentsRequest();
  }

  public static final com.google.protobuf.Descriptors.Descriptor
      getDescriptor() {
    return com.google.ads.googleads.v14.services.ConversionAdjustmentUploadServiceProto.internal_static_google_ads_googleads_v14_services_UploadConversionAdjustmentsRequest_descriptor;
  }

  @java.lang.Override
  protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
      internalGetFieldAccessorTable() {
    return com.google.ads.googleads.v14.services.ConversionAdjustmentUploadServiceProto.internal_static_google_ads_googleads_v14_services_UploadConversionAdjustmentsRequest_fieldAccessorTable
        .ensureFieldAccessorsInitialized(
            com.google.ads.googleads.v14.services.UploadConversionAdjustmentsRequest.class, com.google.ads.googleads.v14.services.UploadConversionAdjustmentsRequest.Builder.class);
  }

  public static final int CUSTOMER_ID_FIELD_NUMBER = 1;
  @SuppressWarnings("serial")
  private volatile java.lang.Object customerId_ = "";
  /**
   * <pre>
   * Required. The ID of the customer performing the upload.
   * </pre>
   *
   * <code>string customer_id = 1 [(.google.api.field_behavior) = REQUIRED];</code>
   * @return The customerId.
   */
  @java.lang.Override
  public java.lang.String getCustomerId() {
    java.lang.Object ref = customerId_;
    if (ref instanceof java.lang.String) {
      return (java.lang.String) ref;
    } else {
      com.google.protobuf.ByteString bs = 
          (com.google.protobuf.ByteString) ref;
      java.lang.String s = bs.toStringUtf8();
      customerId_ = s;
      return s;
    }
  }
  /**
   * <pre>
   * Required. The ID of the customer performing the upload.
   * </pre>
   *
   * <code>string customer_id = 1 [(.google.api.field_behavior) = REQUIRED];</code>
   * @return The bytes for customerId.
   */
  @java.lang.Override
  public com.google.protobuf.ByteString
      getCustomerIdBytes() {
    java.lang.Object ref = customerId_;
    if (ref instanceof java.lang.String) {
      com.google.protobuf.ByteString b = 
          com.google.protobuf.ByteString.copyFromUtf8(
              (java.lang.String) ref);
      customerId_ = b;
      return b;
    } else {
      return (com.google.protobuf.ByteString) ref;
    }
  }

  public static final int CONVERSION_ADJUSTMENTS_FIELD_NUMBER = 2;
  @SuppressWarnings("serial")
  private java.util.List<com.google.ads.googleads.v14.services.ConversionAdjustment> conversionAdjustments_;
  /**
   * <pre>
   * Required. The conversion adjustments that are being uploaded.
   * </pre>
   *
   * <code>repeated .google.ads.googleads.v14.services.ConversionAdjustment conversion_adjustments = 2 [(.google.api.field_behavior) = REQUIRED];</code>
   */
  @java.lang.Override
  public java.util.List<com.google.ads.googleads.v14.services.ConversionAdjustment> getConversionAdjustmentsList() {
    return conversionAdjustments_;
  }
  /**
   * <pre>
   * Required. The conversion adjustments that are being uploaded.
   * </pre>
   *
   * <code>repeated .google.ads.googleads.v14.services.ConversionAdjustment conversion_adjustments = 2 [(.google.api.field_behavior) = REQUIRED];</code>
   */
  @java.lang.Override
  public java.util.List<? extends com.google.ads.googleads.v14.services.ConversionAdjustmentOrBuilder> 
      getConversionAdjustmentsOrBuilderList() {
    return conversionAdjustments_;
  }
  /**
   * <pre>
   * Required. The conversion adjustments that are being uploaded.
   * </pre>
   *
   * <code>repeated .google.ads.googleads.v14.services.ConversionAdjustment conversion_adjustments = 2 [(.google.api.field_behavior) = REQUIRED];</code>
   */
  @java.lang.Override
  public int getConversionAdjustmentsCount() {
    return conversionAdjustments_.size();
  }
  /**
   * <pre>
   * Required. The conversion adjustments that are being uploaded.
   * </pre>
   *
   * <code>repeated .google.ads.googleads.v14.services.ConversionAdjustment conversion_adjustments = 2 [(.google.api.field_behavior) = REQUIRED];</code>
   */
  @java.lang.Override
  public com.google.ads.googleads.v14.services.ConversionAdjustment getConversionAdjustments(int index) {
    return conversionAdjustments_.get(index);
  }
  /**
   * <pre>
   * Required. The conversion adjustments that are being uploaded.
   * </pre>
   *
   * <code>repeated .google.ads.googleads.v14.services.ConversionAdjustment conversion_adjustments = 2 [(.google.api.field_behavior) = REQUIRED];</code>
   */
  @java.lang.Override
  public com.google.ads.googleads.v14.services.ConversionAdjustmentOrBuilder getConversionAdjustmentsOrBuilder(
      int index) {
    return conversionAdjustments_.get(index);
  }

  public static final int PARTIAL_FAILURE_FIELD_NUMBER = 3;
  private boolean partialFailure_ = false;
  /**
   * <pre>
   * Required. If true, successful operations will be carried out and invalid
   * operations will return errors. If false, all operations will be carried out
   * in one transaction if and only if they are all valid. This should always be
   * set to true.
   * See
   * https://developers.google.com/google-ads/api/docs/best-practices/partial-failures
   * for more information about partial failure.
   * </pre>
   *
   * <code>bool partial_failure = 3 [(.google.api.field_behavior) = REQUIRED];</code>
   * @return The partialFailure.
   */
  @java.lang.Override
  public boolean getPartialFailure() {
    return partialFailure_;
  }

  public static final int VALIDATE_ONLY_FIELD_NUMBER = 4;
  private boolean validateOnly_ = false;
  /**
   * <pre>
   * If true, the request is validated but not executed. Only errors are
   * returned, not results.
   * </pre>
   *
   * <code>bool validate_only = 4;</code>
   * @return The validateOnly.
   */
  @java.lang.Override
  public boolean getValidateOnly() {
    return validateOnly_;
  }

  private byte memoizedIsInitialized = -1;
  @java.lang.Override
  public final boolean isInitialized() {
    byte isInitialized = memoizedIsInitialized;
    if (isInitialized == 1) return true;
    if (isInitialized == 0) return false;

    memoizedIsInitialized = 1;
    return true;
  }

  @java.lang.Override
  public void writeTo(com.google.protobuf.CodedOutputStream output)
                      throws java.io.IOException {
    if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(customerId_)) {
      com.google.protobuf.GeneratedMessageV3.writeString(output, 1, customerId_);
    }
    for (int i = 0; i < conversionAdjustments_.size(); i++) {
      output.writeMessage(2, conversionAdjustments_.get(i));
    }
    if (partialFailure_ != false) {
      output.writeBool(3, partialFailure_);
    }
    if (validateOnly_ != false) {
      output.writeBool(4, validateOnly_);
    }
    getUnknownFields().writeTo(output);
  }

  @java.lang.Override
  public int getSerializedSize() {
    int size = memoizedSize;
    if (size != -1) return size;

    size = 0;
    if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(customerId_)) {
      size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, customerId_);
    }
    for (int i = 0; i < conversionAdjustments_.size(); i++) {
      size += com.google.protobuf.CodedOutputStream
        .computeMessageSize(2, conversionAdjustments_.get(i));
    }
    if (partialFailure_ != false) {
      size += com.google.protobuf.CodedOutputStream
        .computeBoolSize(3, partialFailure_);
    }
    if (validateOnly_ != false) {
      size += com.google.protobuf.CodedOutputStream
        .computeBoolSize(4, validateOnly_);
    }
    size += getUnknownFields().getSerializedSize();
    memoizedSize = size;
    return size;
  }

  @java.lang.Override
  public boolean equals(final java.lang.Object obj) {
    if (obj == this) {
     return true;
    }
    if (!(obj instanceof com.google.ads.googleads.v14.services.UploadConversionAdjustmentsRequest)) {
      return super.equals(obj);
    }
    com.google.ads.googleads.v14.services.UploadConversionAdjustmentsRequest other = (com.google.ads.googleads.v14.services.UploadConversionAdjustmentsRequest) obj;

    if (!getCustomerId()
        .equals(other.getCustomerId())) return false;
    if (!getConversionAdjustmentsList()
        .equals(other.getConversionAdjustmentsList())) return false;
    if (getPartialFailure()
        != other.getPartialFailure()) return false;
    if (getValidateOnly()
        != other.getValidateOnly()) return false;
    if (!getUnknownFields().equals(other.getUnknownFields())) return false;
    return true;
  }

  @java.lang.Override
  public int hashCode() {
    if (memoizedHashCode != 0) {
      return memoizedHashCode;
    }
    int hash = 41;
    hash = (19 * hash) + getDescriptor().hashCode();
    hash = (37 * hash) + CUSTOMER_ID_FIELD_NUMBER;
    hash = (53 * hash) + getCustomerId().hashCode();
    if (getConversionAdjustmentsCount() > 0) {
      hash = (37 * hash) + CONVERSION_ADJUSTMENTS_FIELD_NUMBER;
      hash = (53 * hash) + getConversionAdjustmentsList().hashCode();
    }
    hash = (37 * hash) + PARTIAL_FAILURE_FIELD_NUMBER;
    hash = (53 * hash) + com.google.protobuf.Internal.hashBoolean(
        getPartialFailure());
    hash = (37 * hash) + VALIDATE_ONLY_FIELD_NUMBER;
    hash = (53 * hash) + com.google.protobuf.Internal.hashBoolean(
        getValidateOnly());
    hash = (29 * hash) + getUnknownFields().hashCode();
    memoizedHashCode = hash;
    return hash;
  }

  public static com.google.ads.googleads.v14.services.UploadConversionAdjustmentsRequest parseFrom(
      java.nio.ByteBuffer data)
      throws com.google.protobuf.InvalidProtocolBufferException {
    return PARSER.parseFrom(data);
  }
  public static com.google.ads.googleads.v14.services.UploadConversionAdjustmentsRequest parseFrom(
      java.nio.ByteBuffer data,
      com.google.protobuf.ExtensionRegistryLite extensionRegistry)
      throws com.google.protobuf.InvalidProtocolBufferException {
    return PARSER.parseFrom(data, extensionRegistry);
  }
  public static com.google.ads.googleads.v14.services.UploadConversionAdjustmentsRequest parseFrom(
      com.google.protobuf.ByteString data)
      throws com.google.protobuf.InvalidProtocolBufferException {
    return PARSER.parseFrom(data);
  }
  public static com.google.ads.googleads.v14.services.UploadConversionAdjustmentsRequest parseFrom(
      com.google.protobuf.ByteString data,
      com.google.protobuf.ExtensionRegistryLite extensionRegistry)
      throws com.google.protobuf.InvalidProtocolBufferException {
    return PARSER.parseFrom(data, extensionRegistry);
  }
  public static com.google.ads.googleads.v14.services.UploadConversionAdjustmentsRequest parseFrom(byte[] data)
      throws com.google.protobuf.InvalidProtocolBufferException {
    return PARSER.parseFrom(data);
  }
  public static com.google.ads.googleads.v14.services.UploadConversionAdjustmentsRequest parseFrom(
      byte[] data,
      com.google.protobuf.ExtensionRegistryLite extensionRegistry)
      throws com.google.protobuf.InvalidProtocolBufferException {
    return PARSER.parseFrom(data, extensionRegistry);
  }
  public static com.google.ads.googleads.v14.services.UploadConversionAdjustmentsRequest parseFrom(java.io.InputStream input)
      throws java.io.IOException {
    return com.google.protobuf.GeneratedMessageV3
        .parseWithIOException(PARSER, input);
  }
  public static com.google.ads.googleads.v14.services.UploadConversionAdjustmentsRequest parseFrom(
      java.io.InputStream input,
      com.google.protobuf.ExtensionRegistryLite extensionRegistry)
      throws java.io.IOException {
    return com.google.protobuf.GeneratedMessageV3
        .parseWithIOException(PARSER, input, extensionRegistry);
  }

  public static com.google.ads.googleads.v14.services.UploadConversionAdjustmentsRequest parseDelimitedFrom(java.io.InputStream input)
      throws java.io.IOException {
    return com.google.protobuf.GeneratedMessageV3
        .parseDelimitedWithIOException(PARSER, input);
  }

  public static com.google.ads.googleads.v14.services.UploadConversionAdjustmentsRequest parseDelimitedFrom(
      java.io.InputStream input,
      com.google.protobuf.ExtensionRegistryLite extensionRegistry)
      throws java.io.IOException {
    return com.google.protobuf.GeneratedMessageV3
        .parseDelimitedWithIOException(PARSER, input, extensionRegistry);
  }
  public static com.google.ads.googleads.v14.services.UploadConversionAdjustmentsRequest parseFrom(
      com.google.protobuf.CodedInputStream input)
      throws java.io.IOException {
    return com.google.protobuf.GeneratedMessageV3
        .parseWithIOException(PARSER, input);
  }
  public static com.google.ads.googleads.v14.services.UploadConversionAdjustmentsRequest parseFrom(
      com.google.protobuf.CodedInputStream input,
      com.google.protobuf.ExtensionRegistryLite extensionRegistry)
      throws java.io.IOException {
    return com.google.protobuf.GeneratedMessageV3
        .parseWithIOException(PARSER, input, extensionRegistry);
  }

  @java.lang.Override
  public Builder newBuilderForType() { return newBuilder(); }
  public static Builder newBuilder() {
    return DEFAULT_INSTANCE.toBuilder();
  }
  public static Builder newBuilder(com.google.ads.googleads.v14.services.UploadConversionAdjustmentsRequest prototype) {
    return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype);
  }
  @java.lang.Override
  public Builder toBuilder() {
    return this == DEFAULT_INSTANCE
        ? new Builder() : new Builder().mergeFrom(this);
  }

  @java.lang.Override
  protected Builder newBuilderForType(
      com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
    Builder builder = new Builder(parent);
    return builder;
  }
  /**
   * <pre>
   * Request message for
   * [ConversionAdjustmentUploadService.UploadConversionAdjustments][google.ads.googleads.v14.services.ConversionAdjustmentUploadService.UploadConversionAdjustments].
   * </pre>
   *
   * Protobuf type {@code google.ads.googleads.v14.services.UploadConversionAdjustmentsRequest}
   */
  public static final class Builder extends
      com.google.protobuf.GeneratedMessageV3.Builder<Builder> implements
      // @@protoc_insertion_point(builder_implements:google.ads.googleads.v14.services.UploadConversionAdjustmentsRequest)
      com.google.ads.googleads.v14.services.UploadConversionAdjustmentsRequestOrBuilder {
    public static final com.google.protobuf.Descriptors.Descriptor
        getDescriptor() {
      return com.google.ads.googleads.v14.services.ConversionAdjustmentUploadServiceProto.internal_static_google_ads_googleads_v14_services_UploadConversionAdjustmentsRequest_descriptor;
    }

    @java.lang.Override
    protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
        internalGetFieldAccessorTable() {
      return com.google.ads.googleads.v14.services.ConversionAdjustmentUploadServiceProto.internal_static_google_ads_googleads_v14_services_UploadConversionAdjustmentsRequest_fieldAccessorTable
          .ensureFieldAccessorsInitialized(
              com.google.ads.googleads.v14.services.UploadConversionAdjustmentsRequest.class, com.google.ads.googleads.v14.services.UploadConversionAdjustmentsRequest.Builder.class);
    }

    // Construct using com.google.ads.googleads.v14.services.UploadConversionAdjustmentsRequest.newBuilder()
    private Builder() {

    }

    private Builder(
        com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
      super(parent);

    }
    @java.lang.Override
    public Builder clear() {
      super.clear();
      bitField0_ = 0;
      customerId_ = "";
      if (conversionAdjustmentsBuilder_ == null) {
        conversionAdjustments_ = java.util.Collections.emptyList();
      } else {
        conversionAdjustments_ = null;
        conversionAdjustmentsBuilder_.clear();
      }
      bitField0_ = (bitField0_ & ~0x00000002);
      partialFailure_ = false;
      validateOnly_ = false;
      return this;
    }

    @java.lang.Override
    public com.google.protobuf.Descriptors.Descriptor
        getDescriptorForType() {
      return com.google.ads.googleads.v14.services.ConversionAdjustmentUploadServiceProto.internal_static_google_ads_googleads_v14_services_UploadConversionAdjustmentsRequest_descriptor;
    }

    @java.lang.Override
    public com.google.ads.googleads.v14.services.UploadConversionAdjustmentsRequest getDefaultInstanceForType() {
      return com.google.ads.googleads.v14.services.UploadConversionAdjustmentsRequest.getDefaultInstance();
    }

    @java.lang.Override
    public com.google.ads.googleads.v14.services.UploadConversionAdjustmentsRequest build() {
      com.google.ads.googleads.v14.services.UploadConversionAdjustmentsRequest result = buildPartial();
      if (!result.isInitialized()) {
        throw newUninitializedMessageException(result);
      }
      return result;
    }

    @java.lang.Override
    public com.google.ads.googleads.v14.services.UploadConversionAdjustmentsRequest buildPartial() {
      com.google.ads.googleads.v14.services.UploadConversionAdjustmentsRequest result = new com.google.ads.googleads.v14.services.UploadConversionAdjustmentsRequest(this);
      buildPartialRepeatedFields(result);
      if (bitField0_ != 0) { buildPartial0(result); }
      onBuilt();
      return result;
    }

    private void buildPartialRepeatedFields(com.google.ads.googleads.v14.services.UploadConversionAdjustmentsRequest result) {
      if (conversionAdjustmentsBuilder_ == null) {
        if (((bitField0_ & 0x00000002) != 0)) {
          conversionAdjustments_ = java.util.Collections.unmodifiableList(conversionAdjustments_);
          bitField0_ = (bitField0_ & ~0x00000002);
        }
        result.conversionAdjustments_ = conversionAdjustments_;
      } else {
        result.conversionAdjustments_ = conversionAdjustmentsBuilder_.build();
      }
    }

    private void buildPartial0(com.google.ads.googleads.v14.services.UploadConversionAdjustmentsRequest result) {
      int from_bitField0_ = bitField0_;
      if (((from_bitField0_ & 0x00000001) != 0)) {
        result.customerId_ = customerId_;
      }
      if (((from_bitField0_ & 0x00000004) != 0)) {
        result.partialFailure_ = partialFailure_;
      }
      if (((from_bitField0_ & 0x00000008) != 0)) {
        result.validateOnly_ = validateOnly_;
      }
    }

    @java.lang.Override
    public Builder clone() {
      return super.clone();
    }
    @java.lang.Override
    public Builder setField(
        com.google.protobuf.Descriptors.FieldDescriptor field,
        java.lang.Object value) {
      return super.setField(field, value);
    }
    @java.lang.Override
    public Builder clearField(
        com.google.protobuf.Descriptors.FieldDescriptor field) {
      return super.clearField(field);
    }
    @java.lang.Override
    public Builder clearOneof(
        com.google.protobuf.Descriptors.OneofDescriptor oneof) {
      return super.clearOneof(oneof);
    }
    @java.lang.Override
    public Builder setRepeatedField(
        com.google.protobuf.Descriptors.FieldDescriptor field,
        int index, java.lang.Object value) {
      return super.setRepeatedField(field, index, value);
    }
    @java.lang.Override
    public Builder addRepeatedField(
        com.google.protobuf.Descriptors.FieldDescriptor field,
        java.lang.Object value) {
      return super.addRepeatedField(field, value);
    }
    @java.lang.Override
    public Builder mergeFrom(com.google.protobuf.Message other) {
      if (other instanceof com.google.ads.googleads.v14.services.UploadConversionAdjustmentsRequest) {
        return mergeFrom((com.google.ads.googleads.v14.services.UploadConversionAdjustmentsRequest)other);
      } else {
        super.mergeFrom(other);
        return this;
      }
    }

    public Builder mergeFrom(com.google.ads.googleads.v14.services.UploadConversionAdjustmentsRequest other) {
      if (other == com.google.ads.googleads.v14.services.UploadConversionAdjustmentsRequest.getDefaultInstance()) return this;
      if (!other.getCustomerId().isEmpty()) {
        customerId_ = other.customerId_;
        bitField0_ |= 0x00000001;
        onChanged();
      }
      if (conversionAdjustmentsBuilder_ == null) {
        if (!other.conversionAdjustments_.isEmpty()) {
          if (conversionAdjustments_.isEmpty()) {
            conversionAdjustments_ = other.conversionAdjustments_;
            bitField0_ = (bitField0_ & ~0x00000002);
          } else {
            ensureConversionAdjustmentsIsMutable();
            conversionAdjustments_.addAll(other.conversionAdjustments_);
          }
          onChanged();
        }
      } else {
        if (!other.conversionAdjustments_.isEmpty()) {
          if (conversionAdjustmentsBuilder_.isEmpty()) {
            conversionAdjustmentsBuilder_.dispose();
            conversionAdjustmentsBuilder_ = null;
            conversionAdjustments_ = other.conversionAdjustments_;
            bitField0_ = (bitField0_ & ~0x00000002);
            conversionAdjustmentsBuilder_ = 
              com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders ?
                 getConversionAdjustmentsFieldBuilder() : null;
          } else {
            conversionAdjustmentsBuilder_.addAllMessages(other.conversionAdjustments_);
          }
        }
      }
      if (other.getPartialFailure() != false) {
        setPartialFailure(other.getPartialFailure());
      }
      if (other.getValidateOnly() != false) {
        setValidateOnly(other.getValidateOnly());
      }
      this.mergeUnknownFields(other.getUnknownFields());
      onChanged();
      return this;
    }

    @java.lang.Override
    public final boolean isInitialized() {
      return true;
    }

    @java.lang.Override
    public Builder mergeFrom(
        com.google.protobuf.CodedInputStream input,
        com.google.protobuf.ExtensionRegistryLite extensionRegistry)
        throws java.io.IOException {
      if (extensionRegistry == null) {
        throw new java.lang.NullPointerException();
      }
      try {
        boolean done = false;
        while (!done) {
          int tag = input.readTag();
          switch (tag) {
            case 0:
              done = true;
              break;
            case 10: {
              customerId_ = input.readStringRequireUtf8();
              bitField0_ |= 0x00000001;
              break;
            } // case 10
            case 18: {
              com.google.ads.googleads.v14.services.ConversionAdjustment m =
                  input.readMessage(
                      com.google.ads.googleads.v14.services.ConversionAdjustment.parser(),
                      extensionRegistry);
              if (conversionAdjustmentsBuilder_ == null) {
                ensureConversionAdjustmentsIsMutable();
                conversionAdjustments_.add(m);
              } else {
                conversionAdjustmentsBuilder_.addMessage(m);
              }
              break;
            } // case 18
            case 24: {
              partialFailure_ = input.readBool();
              bitField0_ |= 0x00000004;
              break;
            } // case 24
            case 32: {
              validateOnly_ = input.readBool();
              bitField0_ |= 0x00000008;
              break;
            } // case 32
            default: {
              if (!super.parseUnknownField(input, extensionRegistry, tag)) {
                done = true; // was an endgroup tag
              }
              break;
            } // default:
          } // switch (tag)
        } // while (!done)
      } catch (com.google.protobuf.InvalidProtocolBufferException e) {
        throw e.unwrapIOException();
      } finally {
        onChanged();
      } // finally
      return this;
    }
    private int bitField0_;

    private java.lang.Object customerId_ = "";
    /**
     * <pre>
     * Required. The ID of the customer performing the upload.
     * </pre>
     *
     * <code>string customer_id = 1 [(.google.api.field_behavior) = REQUIRED];</code>
     * @return The customerId.
     */
    public java.lang.String getCustomerId() {
      java.lang.Object ref = customerId_;
      if (!(ref instanceof java.lang.String)) {
        com.google.protobuf.ByteString bs =
            (com.google.protobuf.ByteString) ref;
        java.lang.String s = bs.toStringUtf8();
        customerId_ = s;
        return s;
      } else {
        return (java.lang.String) ref;
      }
    }
    /**
     * <pre>
     * Required. The ID of the customer performing the upload.
     * </pre>
     *
     * <code>string customer_id = 1 [(.google.api.field_behavior) = REQUIRED];</code>
     * @return The bytes for customerId.
     */
    public com.google.protobuf.ByteString
        getCustomerIdBytes() {
      java.lang.Object ref = customerId_;
      if (ref instanceof String) {
        com.google.protobuf.ByteString b = 
            com.google.protobuf.ByteString.copyFromUtf8(
                (java.lang.String) ref);
        customerId_ = b;
        return b;
      } else {
        return (com.google.protobuf.ByteString) ref;
      }
    }
    /**
     * <pre>
     * Required. The ID of the customer performing the upload.
     * </pre>
     *
     * <code>string customer_id = 1 [(.google.api.field_behavior) = REQUIRED];</code>
     * @param value The customerId to set.
     * @return This builder for chaining.
     */
    public Builder setCustomerId(
        java.lang.String value) {
      if (value == null) { throw new NullPointerException(); }
      customerId_ = value;
      bitField0_ |= 0x00000001;
      onChanged();
      return this;
    }
    /**
     * <pre>
     * Required. The ID of the customer performing the upload.
     * </pre>
     *
     * <code>string customer_id = 1 [(.google.api.field_behavior) = REQUIRED];</code>
     * @return This builder for chaining.
     */
    public Builder clearCustomerId() {
      customerId_ = getDefaultInstance().getCustomerId();
      bitField0_ = (bitField0_ & ~0x00000001);
      onChanged();
      return this;
    }
    /**
     * <pre>
     * Required. The ID of the customer performing the upload.
     * </pre>
     *
     * <code>string customer_id = 1 [(.google.api.field_behavior) = REQUIRED];</code>
     * @param value The bytes for customerId to set.
     * @return This builder for chaining.
     */
    public Builder setCustomerIdBytes(
        com.google.protobuf.ByteString value) {
      if (value == null) { throw new NullPointerException(); }
      checkByteStringIsUtf8(value);
      customerId_ = value;
      bitField0_ |= 0x00000001;
      onChanged();
      return this;
    }

    private java.util.List<com.google.ads.googleads.v14.services.ConversionAdjustment> conversionAdjustments_ =
      java.util.Collections.emptyList();
    private void ensureConversionAdjustmentsIsMutable() {
      if (!((bitField0_ & 0x00000002) != 0)) {
        conversionAdjustments_ = new java.util.ArrayList<com.google.ads.googleads.v14.services.ConversionAdjustment>(conversionAdjustments_);
        bitField0_ |= 0x00000002;
       }
    }

    private com.google.protobuf.RepeatedFieldBuilderV3<
        com.google.ads.googleads.v14.services.ConversionAdjustment, com.google.ads.googleads.v14.services.ConversionAdjustment.Builder, com.google.ads.googleads.v14.services.ConversionAdjustmentOrBuilder> conversionAdjustmentsBuilder_;

    /**
     * <pre>
     * Required. The conversion adjustments that are being uploaded.
     * </pre>
     *
     * <code>repeated .google.ads.googleads.v14.services.ConversionAdjustment conversion_adjustments = 2 [(.google.api.field_behavior) = REQUIRED];</code>
     */
    public java.util.List<com.google.ads.googleads.v14.services.ConversionAdjustment> getConversionAdjustmentsList() {
      if (conversionAdjustmentsBuilder_ == null) {
        return java.util.Collections.unmodifiableList(conversionAdjustments_);
      } else {
        return conversionAdjustmentsBuilder_.getMessageList();
      }
    }
    /**
     * <pre>
     * Required. The conversion adjustments that are being uploaded.
     * </pre>
     *
     * <code>repeated .google.ads.googleads.v14.services.ConversionAdjustment conversion_adjustments = 2 [(.google.api.field_behavior) = REQUIRED];</code>
     */
    public int getConversionAdjustmentsCount() {
      if (conversionAdjustmentsBuilder_ == null) {
        return conversionAdjustments_.size();
      } else {
        return conversionAdjustmentsBuilder_.getCount();
      }
    }
    /**
     * <pre>
     * Required. The conversion adjustments that are being uploaded.
     * </pre>
     *
     * <code>repeated .google.ads.googleads.v14.services.ConversionAdjustment conversion_adjustments = 2 [(.google.api.field_behavior) = REQUIRED];</code>
     */
    public com.google.ads.googleads.v14.services.ConversionAdjustment getConversionAdjustments(int index) {
      if (conversionAdjustmentsBuilder_ == null) {
        return conversionAdjustments_.get(index);
      } else {
        return conversionAdjustmentsBuilder_.getMessage(index);
      }
    }
    /**
     * <pre>
     * Required. The conversion adjustments that are being uploaded.
     * </pre>
     *
     * <code>repeated .google.ads.googleads.v14.services.ConversionAdjustment conversion_adjustments = 2 [(.google.api.field_behavior) = REQUIRED];</code>
     */
    public Builder setConversionAdjustments(
        int index, com.google.ads.googleads.v14.services.ConversionAdjustment value) {
      if (conversionAdjustmentsBuilder_ == null) {
        if (value == null) {
          throw new NullPointerException();
        }
        ensureConversionAdjustmentsIsMutable();
        conversionAdjustments_.set(index, value);
        onChanged();
      } else {
        conversionAdjustmentsBuilder_.setMessage(index, value);
      }
      return this;
    }
    /**
     * <pre>
     * Required. The conversion adjustments that are being uploaded.
     * </pre>
     *
     * <code>repeated .google.ads.googleads.v14.services.ConversionAdjustment conversion_adjustments = 2 [(.google.api.field_behavior) = REQUIRED];</code>
     */
    public Builder setConversionAdjustments(
        int index, com.google.ads.googleads.v14.services.ConversionAdjustment.Builder builderForValue) {
      if (conversionAdjustmentsBuilder_ == null) {
        ensureConversionAdjustmentsIsMutable();
        conversionAdjustments_.set(index, builderForValue.build());
        onChanged();
      } else {
        conversionAdjustmentsBuilder_.setMessage(index, builderForValue.build());
      }
      return this;
    }
    /**
     * <pre>
     * Required. The conversion adjustments that are being uploaded.
     * </pre>
     *
     * <code>repeated .google.ads.googleads.v14.services.ConversionAdjustment conversion_adjustments = 2 [(.google.api.field_behavior) = REQUIRED];</code>
     */
    public Builder addConversionAdjustments(com.google.ads.googleads.v14.services.ConversionAdjustment value) {
      if (conversionAdjustmentsBuilder_ == null) {
        if (value == null) {
          throw new NullPointerException();
        }
        ensureConversionAdjustmentsIsMutable();
        conversionAdjustments_.add(value);
        onChanged();
      } else {
        conversionAdjustmentsBuilder_.addMessage(value);
      }
      return this;
    }
    /**
     * <pre>
     * Required. The conversion adjustments that are being uploaded.
     * </pre>
     *
     * <code>repeated .google.ads.googleads.v14.services.ConversionAdjustment conversion_adjustments = 2 [(.google.api.field_behavior) = REQUIRED];</code>
     */
    public Builder addConversionAdjustments(
        int index, com.google.ads.googleads.v14.services.ConversionAdjustment value) {
      if (conversionAdjustmentsBuilder_ == null) {
        if (value == null) {
          throw new NullPointerException();
        }
        ensureConversionAdjustmentsIsMutable();
        conversionAdjustments_.add(index, value);
        onChanged();
      } else {
        conversionAdjustmentsBuilder_.addMessage(index, value);
      }
      return this;
    }
    /**
     * <pre>
     * Required. The conversion adjustments that are being uploaded.
     * </pre>
     *
     * <code>repeated .google.ads.googleads.v14.services.ConversionAdjustment conversion_adjustments = 2 [(.google.api.field_behavior) = REQUIRED];</code>
     */
    public Builder addConversionAdjustments(
        com.google.ads.googleads.v14.services.ConversionAdjustment.Builder builderForValue) {
      if (conversionAdjustmentsBuilder_ == null) {
        ensureConversionAdjustmentsIsMutable();
        conversionAdjustments_.add(builderForValue.build());
        onChanged();
      } else {
        conversionAdjustmentsBuilder_.addMessage(builderForValue.build());
      }
      return this;
    }
    /**
     * <pre>
     * Required. The conversion adjustments that are being uploaded.
     * </pre>
     *
     * <code>repeated .google.ads.googleads.v14.services.ConversionAdjustment conversion_adjustments = 2 [(.google.api.field_behavior) = REQUIRED];</code>
     */
    public Builder addConversionAdjustments(
        int index, com.google.ads.googleads.v14.services.ConversionAdjustment.Builder builderForValue) {
      if (conversionAdjustmentsBuilder_ == null) {
        ensureConversionAdjustmentsIsMutable();
        conversionAdjustments_.add(index, builderForValue.build());
        onChanged();
      } else {
        conversionAdjustmentsBuilder_.addMessage(index, builderForValue.build());
      }
      return this;
    }
    /**
     * <pre>
     * Required. The conversion adjustments that are being uploaded.
     * </pre>
     *
     * <code>repeated .google.ads.googleads.v14.services.ConversionAdjustment conversion_adjustments = 2 [(.google.api.field_behavior) = REQUIRED];</code>
     */
    public Builder addAllConversionAdjustments(
        java.lang.Iterable<? extends com.google.ads.googleads.v14.services.ConversionAdjustment> values) {
      if (conversionAdjustmentsBuilder_ == null) {
        ensureConversionAdjustmentsIsMutable();
        com.google.protobuf.AbstractMessageLite.Builder.addAll(
            values, conversionAdjustments_);
        onChanged();
      } else {
        conversionAdjustmentsBuilder_.addAllMessages(values);
      }
      return this;
    }
    /**
     * <pre>
     * Required. The conversion adjustments that are being uploaded.
     * </pre>
     *
     * <code>repeated .google.ads.googleads.v14.services.ConversionAdjustment conversion_adjustments = 2 [(.google.api.field_behavior) = REQUIRED];</code>
     */
    public Builder clearConversionAdjustments() {
      if (conversionAdjustmentsBuilder_ == null) {
        conversionAdjustments_ = java.util.Collections.emptyList();
        bitField0_ = (bitField0_ & ~0x00000002);
        onChanged();
      } else {
        conversionAdjustmentsBuilder_.clear();
      }
      return this;
    }
    /**
     * <pre>
     * Required. The conversion adjustments that are being uploaded.
     * </pre>
     *
     * <code>repeated .google.ads.googleads.v14.services.ConversionAdjustment conversion_adjustments = 2 [(.google.api.field_behavior) = REQUIRED];</code>
     */
    public Builder removeConversionAdjustments(int index) {
      if (conversionAdjustmentsBuilder_ == null) {
        ensureConversionAdjustmentsIsMutable();
        conversionAdjustments_.remove(index);
        onChanged();
      } else {
        conversionAdjustmentsBuilder_.remove(index);
      }
      return this;
    }
    /**
     * <pre>
     * Required. The conversion adjustments that are being uploaded.
     * </pre>
     *
     * <code>repeated .google.ads.googleads.v14.services.ConversionAdjustment conversion_adjustments = 2 [(.google.api.field_behavior) = REQUIRED];</code>
     */
    public com.google.ads.googleads.v14.services.ConversionAdjustment.Builder getConversionAdjustmentsBuilder(
        int index) {
      return getConversionAdjustmentsFieldBuilder().getBuilder(index);
    }
    /**
     * <pre>
     * Required. The conversion adjustments that are being uploaded.
     * </pre>
     *
     * <code>repeated .google.ads.googleads.v14.services.ConversionAdjustment conversion_adjustments = 2 [(.google.api.field_behavior) = REQUIRED];</code>
     */
    public com.google.ads.googleads.v14.services.ConversionAdjustmentOrBuilder getConversionAdjustmentsOrBuilder(
        int index) {
      if (conversionAdjustmentsBuilder_ == null) {
        return conversionAdjustments_.get(index);  } else {
        return conversionAdjustmentsBuilder_.getMessageOrBuilder(index);
      }
    }
    /**
     * <pre>
     * Required. The conversion adjustments that are being uploaded.
     * </pre>
     *
     * <code>repeated .google.ads.googleads.v14.services.ConversionAdjustment conversion_adjustments = 2 [(.google.api.field_behavior) = REQUIRED];</code>
     */
    public java.util.List<? extends com.google.ads.googleads.v14.services.ConversionAdjustmentOrBuilder> 
         getConversionAdjustmentsOrBuilderList() {
      if (conversionAdjustmentsBuilder_ != null) {
        return conversionAdjustmentsBuilder_.getMessageOrBuilderList();
      } else {
        return java.util.Collections.unmodifiableList(conversionAdjustments_);
      }
    }
    /**
     * <pre>
     * Required. The conversion adjustments that are being uploaded.
     * </pre>
     *
     * <code>repeated .google.ads.googleads.v14.services.ConversionAdjustment conversion_adjustments = 2 [(.google.api.field_behavior) = REQUIRED];</code>
     */
    public com.google.ads.googleads.v14.services.ConversionAdjustment.Builder addConversionAdjustmentsBuilder() {
      return getConversionAdjustmentsFieldBuilder().addBuilder(
          com.google.ads.googleads.v14.services.ConversionAdjustment.getDefaultInstance());
    }
    /**
     * <pre>
     * Required. The conversion adjustments that are being uploaded.
     * </pre>
     *
     * <code>repeated .google.ads.googleads.v14.services.ConversionAdjustment conversion_adjustments = 2 [(.google.api.field_behavior) = REQUIRED];</code>
     */
    public com.google.ads.googleads.v14.services.ConversionAdjustment.Builder addConversionAdjustmentsBuilder(
        int index) {
      return getConversionAdjustmentsFieldBuilder().addBuilder(
          index, com.google.ads.googleads.v14.services.ConversionAdjustment.getDefaultInstance());
    }
    /**
     * <pre>
     * Required. The conversion adjustments that are being uploaded.
     * </pre>
     *
     * <code>repeated .google.ads.googleads.v14.services.ConversionAdjustment conversion_adjustments = 2 [(.google.api.field_behavior) = REQUIRED];</code>
     */
    public java.util.List<com.google.ads.googleads.v14.services.ConversionAdjustment.Builder> 
         getConversionAdjustmentsBuilderList() {
      return getConversionAdjustmentsFieldBuilder().getBuilderList();
    }
    private com.google.protobuf.RepeatedFieldBuilderV3<
        com.google.ads.googleads.v14.services.ConversionAdjustment, com.google.ads.googleads.v14.services.ConversionAdjustment.Builder, com.google.ads.googleads.v14.services.ConversionAdjustmentOrBuilder> 
        getConversionAdjustmentsFieldBuilder() {
      if (conversionAdjustmentsBuilder_ == null) {
        conversionAdjustmentsBuilder_ = new com.google.protobuf.RepeatedFieldBuilderV3<
            com.google.ads.googleads.v14.services.ConversionAdjustment, com.google.ads.googleads.v14.services.ConversionAdjustment.Builder, com.google.ads.googleads.v14.services.ConversionAdjustmentOrBuilder>(
                conversionAdjustments_,
                ((bitField0_ & 0x00000002) != 0),
                getParentForChildren(),
                isClean());
        conversionAdjustments_ = null;
      }
      return conversionAdjustmentsBuilder_;
    }

    private boolean partialFailure_ ;
    /**
     * <pre>
     * Required. If true, successful operations will be carried out and invalid
     * operations will return errors. If false, all operations will be carried out
     * in one transaction if and only if they are all valid. This should always be
     * set to true.
     * See
     * https://developers.google.com/google-ads/api/docs/best-practices/partial-failures
     * for more information about partial failure.
     * </pre>
     *
     * <code>bool partial_failure = 3 [(.google.api.field_behavior) = REQUIRED];</code>
     * @return The partialFailure.
     */
    @java.lang.Override
    public boolean getPartialFailure() {
      return partialFailure_;
    }
    /**
     * <pre>
     * Required. If true, successful operations will be carried out and invalid
     * operations will return errors. If false, all operations will be carried out
     * in one transaction if and only if they are all valid. This should always be
     * set to true.
     * See
     * https://developers.google.com/google-ads/api/docs/best-practices/partial-failures
     * for more information about partial failure.
     * </pre>
     *
     * <code>bool partial_failure = 3 [(.google.api.field_behavior) = REQUIRED];</code>
     * @param value The partialFailure to set.
     * @return This builder for chaining.
     */
    public Builder setPartialFailure(boolean value) {

      partialFailure_ = value;
      bitField0_ |= 0x00000004;
      onChanged();
      return this;
    }
    /**
     * <pre>
     * Required. If true, successful operations will be carried out and invalid
     * operations will return errors. If false, all operations will be carried out
     * in one transaction if and only if they are all valid. This should always be
     * set to true.
     * See
     * https://developers.google.com/google-ads/api/docs/best-practices/partial-failures
     * for more information about partial failure.
     * </pre>
     *
     * <code>bool partial_failure = 3 [(.google.api.field_behavior) = REQUIRED];</code>
     * @return This builder for chaining.
     */
    public Builder clearPartialFailure() {
      bitField0_ = (bitField0_ & ~0x00000004);
      partialFailure_ = false;
      onChanged();
      return this;
    }

    private boolean validateOnly_ ;
    /**
     * <pre>
     * If true, the request is validated but not executed. Only errors are
     * returned, not results.
     * </pre>
     *
     * <code>bool validate_only = 4;</code>
     * @return The validateOnly.
     */
    @java.lang.Override
    public boolean getValidateOnly() {
      return validateOnly_;
    }
    /**
     * <pre>
     * If true, the request is validated but not executed. Only errors are
     * returned, not results.
     * </pre>
     *
     * <code>bool validate_only = 4;</code>
     * @param value The validateOnly to set.
     * @return This builder for chaining.
     */
    public Builder setValidateOnly(boolean value) {

      validateOnly_ = value;
      bitField0_ |= 0x00000008;
      onChanged();
      return this;
    }
    /**
     * <pre>
     * If true, the request is validated but not executed. Only errors are
     * returned, not results.
     * </pre>
     *
     * <code>bool validate_only = 4;</code>
     * @return This builder for chaining.
     */
    public Builder clearValidateOnly() {
      bitField0_ = (bitField0_ & ~0x00000008);
      validateOnly_ = false;
      onChanged();
      return this;
    }
    @java.lang.Override
    public final Builder setUnknownFields(
        final com.google.protobuf.UnknownFieldSet unknownFields) {
      return super.setUnknownFields(unknownFields);
    }

    @java.lang.Override
    public final Builder mergeUnknownFields(
        final com.google.protobuf.UnknownFieldSet unknownFields) {
      return super.mergeUnknownFields(unknownFields);
    }


    // @@protoc_insertion_point(builder_scope:google.ads.googleads.v14.services.UploadConversionAdjustmentsRequest)
  }

  // @@protoc_insertion_point(class_scope:google.ads.googleads.v14.services.UploadConversionAdjustmentsRequest)
  private static final com.google.ads.googleads.v14.services.UploadConversionAdjustmentsRequest DEFAULT_INSTANCE;
  static {
    DEFAULT_INSTANCE = new com.google.ads.googleads.v14.services.UploadConversionAdjustmentsRequest();
  }

  public static com.google.ads.googleads.v14.services.UploadConversionAdjustmentsRequest getDefaultInstance() {
    return DEFAULT_INSTANCE;
  }

  private static final com.google.protobuf.Parser<UploadConversionAdjustmentsRequest>
      PARSER = new com.google.protobuf.AbstractParser<UploadConversionAdjustmentsRequest>() {
    @java.lang.Override
    public UploadConversionAdjustmentsRequest parsePartialFrom(
        com.google.protobuf.CodedInputStream input,
        com.google.protobuf.ExtensionRegistryLite extensionRegistry)
        throws com.google.protobuf.InvalidProtocolBufferException {
      Builder builder = newBuilder();
      try {
        builder.mergeFrom(input, extensionRegistry);
      } catch (com.google.protobuf.InvalidProtocolBufferException e) {
        throw e.setUnfinishedMessage(builder.buildPartial());
      } catch (com.google.protobuf.UninitializedMessageException e) {
        throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial());
      } catch (java.io.IOException e) {
        throw new com.google.protobuf.InvalidProtocolBufferException(e)
            .setUnfinishedMessage(builder.buildPartial());
      }
      return builder.buildPartial();
    }
  };

  public static com.google.protobuf.Parser<UploadConversionAdjustmentsRequest> parser() {
    return PARSER;
  }

  @java.lang.Override
  public com.google.protobuf.Parser<UploadConversionAdjustmentsRequest> getParserForType() {
    return PARSER;
  }

  @java.lang.Override
  public com.google.ads.googleads.v14.services.UploadConversionAdjustmentsRequest getDefaultInstanceForType() {
    return DEFAULT_INSTANCE;
  }

}

