// Generated by the protocol buffer compiler.  DO NOT EDIT!
// source: google/privacy/dlp/v2beta1/dlp.proto

package com.google.privacy.dlp.v2beta1;

/**
 * <pre>
 * Privacy metric to compute for reidentification risk analysis.
 * </pre>
 *
 * Protobuf type {@code google.privacy.dlp.v2beta1.PrivacyMetric}
 */
public  final class PrivacyMetric extends
    com.google.protobuf.GeneratedMessageV3 implements
    // @@protoc_insertion_point(message_implements:google.privacy.dlp.v2beta1.PrivacyMetric)
    PrivacyMetricOrBuilder {
private static final long serialVersionUID = 0L;
  // Use PrivacyMetric.newBuilder() to construct.
  private PrivacyMetric(com.google.protobuf.GeneratedMessageV3.Builder<?> builder) {
    super(builder);
  }
  private PrivacyMetric() {
  }

  @java.lang.Override
  public final com.google.protobuf.UnknownFieldSet
  getUnknownFields() {
    return this.unknownFields;
  }
  private PrivacyMetric(
      com.google.protobuf.CodedInputStream input,
      com.google.protobuf.ExtensionRegistryLite extensionRegistry)
      throws com.google.protobuf.InvalidProtocolBufferException {
    this();
    if (extensionRegistry == null) {
      throw new java.lang.NullPointerException();
    }
    int mutable_bitField0_ = 0;
    com.google.protobuf.UnknownFieldSet.Builder unknownFields =
        com.google.protobuf.UnknownFieldSet.newBuilder();
    try {
      boolean done = false;
      while (!done) {
        int tag = input.readTag();
        switch (tag) {
          case 0:
            done = true;
            break;
          default: {
            if (!parseUnknownFieldProto3(
                input, unknownFields, extensionRegistry, tag)) {
              done = true;
            }
            break;
          }
          case 10: {
            com.google.privacy.dlp.v2beta1.PrivacyMetric.NumericalStatsConfig.Builder subBuilder = null;
            if (typeCase_ == 1) {
              subBuilder = ((com.google.privacy.dlp.v2beta1.PrivacyMetric.NumericalStatsConfig) type_).toBuilder();
            }
            type_ =
                input.readMessage(com.google.privacy.dlp.v2beta1.PrivacyMetric.NumericalStatsConfig.parser(), extensionRegistry);
            if (subBuilder != null) {
              subBuilder.mergeFrom((com.google.privacy.dlp.v2beta1.PrivacyMetric.NumericalStatsConfig) type_);
              type_ = subBuilder.buildPartial();
            }
            typeCase_ = 1;
            break;
          }
          case 18: {
            com.google.privacy.dlp.v2beta1.PrivacyMetric.CategoricalStatsConfig.Builder subBuilder = null;
            if (typeCase_ == 2) {
              subBuilder = ((com.google.privacy.dlp.v2beta1.PrivacyMetric.CategoricalStatsConfig) type_).toBuilder();
            }
            type_ =
                input.readMessage(com.google.privacy.dlp.v2beta1.PrivacyMetric.CategoricalStatsConfig.parser(), extensionRegistry);
            if (subBuilder != null) {
              subBuilder.mergeFrom((com.google.privacy.dlp.v2beta1.PrivacyMetric.CategoricalStatsConfig) type_);
              type_ = subBuilder.buildPartial();
            }
            typeCase_ = 2;
            break;
          }
          case 26: {
            com.google.privacy.dlp.v2beta1.PrivacyMetric.KAnonymityConfig.Builder subBuilder = null;
            if (typeCase_ == 3) {
              subBuilder = ((com.google.privacy.dlp.v2beta1.PrivacyMetric.KAnonymityConfig) type_).toBuilder();
            }
            type_ =
                input.readMessage(com.google.privacy.dlp.v2beta1.PrivacyMetric.KAnonymityConfig.parser(), extensionRegistry);
            if (subBuilder != null) {
              subBuilder.mergeFrom((com.google.privacy.dlp.v2beta1.PrivacyMetric.KAnonymityConfig) type_);
              type_ = subBuilder.buildPartial();
            }
            typeCase_ = 3;
            break;
          }
          case 34: {
            com.google.privacy.dlp.v2beta1.PrivacyMetric.LDiversityConfig.Builder subBuilder = null;
            if (typeCase_ == 4) {
              subBuilder = ((com.google.privacy.dlp.v2beta1.PrivacyMetric.LDiversityConfig) type_).toBuilder();
            }
            type_ =
                input.readMessage(com.google.privacy.dlp.v2beta1.PrivacyMetric.LDiversityConfig.parser(), extensionRegistry);
            if (subBuilder != null) {
              subBuilder.mergeFrom((com.google.privacy.dlp.v2beta1.PrivacyMetric.LDiversityConfig) type_);
              type_ = subBuilder.buildPartial();
            }
            typeCase_ = 4;
            break;
          }
        }
      }
    } catch (com.google.protobuf.InvalidProtocolBufferException e) {
      throw e.setUnfinishedMessage(this);
    } catch (java.io.IOException e) {
      throw new com.google.protobuf.InvalidProtocolBufferException(
          e).setUnfinishedMessage(this);
    } finally {
      this.unknownFields = unknownFields.build();
      makeExtensionsImmutable();
    }
  }
  public static final com.google.protobuf.Descriptors.Descriptor
      getDescriptor() {
    return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_PrivacyMetric_descriptor;
  }

  protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
      internalGetFieldAccessorTable() {
    return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_PrivacyMetric_fieldAccessorTable
        .ensureFieldAccessorsInitialized(
            com.google.privacy.dlp.v2beta1.PrivacyMetric.class, com.google.privacy.dlp.v2beta1.PrivacyMetric.Builder.class);
  }

  public interface NumericalStatsConfigOrBuilder extends
      // @@protoc_insertion_point(interface_extends:google.privacy.dlp.v2beta1.PrivacyMetric.NumericalStatsConfig)
      com.google.protobuf.MessageOrBuilder {

    /**
     * <pre>
     * Field to compute numerical stats on. Supported types are
     * integer, float, date, datetime, timestamp, time.
     * </pre>
     *
     * <code>.google.privacy.dlp.v2beta1.FieldId field = 1;</code>
     */
    boolean hasField();
    /**
     * <pre>
     * Field to compute numerical stats on. Supported types are
     * integer, float, date, datetime, timestamp, time.
     * </pre>
     *
     * <code>.google.privacy.dlp.v2beta1.FieldId field = 1;</code>
     */
    com.google.privacy.dlp.v2beta1.FieldId getField();
    /**
     * <pre>
     * Field to compute numerical stats on. Supported types are
     * integer, float, date, datetime, timestamp, time.
     * </pre>
     *
     * <code>.google.privacy.dlp.v2beta1.FieldId field = 1;</code>
     */
    com.google.privacy.dlp.v2beta1.FieldIdOrBuilder getFieldOrBuilder();
  }
  /**
   * <pre>
   * Compute numerical stats over an individual column, including
   * min, max, and quantiles.
   * </pre>
   *
   * Protobuf type {@code google.privacy.dlp.v2beta1.PrivacyMetric.NumericalStatsConfig}
   */
  public  static final class NumericalStatsConfig extends
      com.google.protobuf.GeneratedMessageV3 implements
      // @@protoc_insertion_point(message_implements:google.privacy.dlp.v2beta1.PrivacyMetric.NumericalStatsConfig)
      NumericalStatsConfigOrBuilder {
  private static final long serialVersionUID = 0L;
    // Use NumericalStatsConfig.newBuilder() to construct.
    private NumericalStatsConfig(com.google.protobuf.GeneratedMessageV3.Builder<?> builder) {
      super(builder);
    }
    private NumericalStatsConfig() {
    }

    @java.lang.Override
    public final com.google.protobuf.UnknownFieldSet
    getUnknownFields() {
      return this.unknownFields;
    }
    private NumericalStatsConfig(
        com.google.protobuf.CodedInputStream input,
        com.google.protobuf.ExtensionRegistryLite extensionRegistry)
        throws com.google.protobuf.InvalidProtocolBufferException {
      this();
      if (extensionRegistry == null) {
        throw new java.lang.NullPointerException();
      }
      int mutable_bitField0_ = 0;
      com.google.protobuf.UnknownFieldSet.Builder unknownFields =
          com.google.protobuf.UnknownFieldSet.newBuilder();
      try {
        boolean done = false;
        while (!done) {
          int tag = input.readTag();
          switch (tag) {
            case 0:
              done = true;
              break;
            default: {
              if (!parseUnknownFieldProto3(
                  input, unknownFields, extensionRegistry, tag)) {
                done = true;
              }
              break;
            }
            case 10: {
              com.google.privacy.dlp.v2beta1.FieldId.Builder subBuilder = null;
              if (field_ != null) {
                subBuilder = field_.toBuilder();
              }
              field_ = input.readMessage(com.google.privacy.dlp.v2beta1.FieldId.parser(), extensionRegistry);
              if (subBuilder != null) {
                subBuilder.mergeFrom(field_);
                field_ = subBuilder.buildPartial();
              }

              break;
            }
          }
        }
      } catch (com.google.protobuf.InvalidProtocolBufferException e) {
        throw e.setUnfinishedMessage(this);
      } catch (java.io.IOException e) {
        throw new com.google.protobuf.InvalidProtocolBufferException(
            e).setUnfinishedMessage(this);
      } finally {
        this.unknownFields = unknownFields.build();
        makeExtensionsImmutable();
      }
    }
    public static final com.google.protobuf.Descriptors.Descriptor
        getDescriptor() {
      return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_PrivacyMetric_NumericalStatsConfig_descriptor;
    }

    protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
        internalGetFieldAccessorTable() {
      return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_PrivacyMetric_NumericalStatsConfig_fieldAccessorTable
          .ensureFieldAccessorsInitialized(
              com.google.privacy.dlp.v2beta1.PrivacyMetric.NumericalStatsConfig.class, com.google.privacy.dlp.v2beta1.PrivacyMetric.NumericalStatsConfig.Builder.class);
    }

    public static final int FIELD_FIELD_NUMBER = 1;
    private com.google.privacy.dlp.v2beta1.FieldId field_;
    /**
     * <pre>
     * Field to compute numerical stats on. Supported types are
     * integer, float, date, datetime, timestamp, time.
     * </pre>
     *
     * <code>.google.privacy.dlp.v2beta1.FieldId field = 1;</code>
     */
    public boolean hasField() {
      return field_ != null;
    }
    /**
     * <pre>
     * Field to compute numerical stats on. Supported types are
     * integer, float, date, datetime, timestamp, time.
     * </pre>
     *
     * <code>.google.privacy.dlp.v2beta1.FieldId field = 1;</code>
     */
    public com.google.privacy.dlp.v2beta1.FieldId getField() {
      return field_ == null ? com.google.privacy.dlp.v2beta1.FieldId.getDefaultInstance() : field_;
    }
    /**
     * <pre>
     * Field to compute numerical stats on. Supported types are
     * integer, float, date, datetime, timestamp, time.
     * </pre>
     *
     * <code>.google.privacy.dlp.v2beta1.FieldId field = 1;</code>
     */
    public com.google.privacy.dlp.v2beta1.FieldIdOrBuilder getFieldOrBuilder() {
      return getField();
    }

    private byte memoizedIsInitialized = -1;
    public final boolean isInitialized() {
      byte isInitialized = memoizedIsInitialized;
      if (isInitialized == 1) return true;
      if (isInitialized == 0) return false;

      memoizedIsInitialized = 1;
      return true;
    }

    public void writeTo(com.google.protobuf.CodedOutputStream output)
                        throws java.io.IOException {
      if (field_ != null) {
        output.writeMessage(1, getField());
      }
      unknownFields.writeTo(output);
    }

    public int getSerializedSize() {
      int size = memoizedSize;
      if (size != -1) return size;

      size = 0;
      if (field_ != null) {
        size += com.google.protobuf.CodedOutputStream
          .computeMessageSize(1, getField());
      }
      size += unknownFields.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.privacy.dlp.v2beta1.PrivacyMetric.NumericalStatsConfig)) {
        return super.equals(obj);
      }
      com.google.privacy.dlp.v2beta1.PrivacyMetric.NumericalStatsConfig other = (com.google.privacy.dlp.v2beta1.PrivacyMetric.NumericalStatsConfig) obj;

      boolean result = true;
      result = result && (hasField() == other.hasField());
      if (hasField()) {
        result = result && getField()
            .equals(other.getField());
      }
      result = result && unknownFields.equals(other.unknownFields);
      return result;
    }

    @java.lang.Override
    public int hashCode() {
      if (memoizedHashCode != 0) {
        return memoizedHashCode;
      }
      int hash = 41;
      hash = (19 * hash) + getDescriptor().hashCode();
      if (hasField()) {
        hash = (37 * hash) + FIELD_FIELD_NUMBER;
        hash = (53 * hash) + getField().hashCode();
      }
      hash = (29 * hash) + unknownFields.hashCode();
      memoizedHashCode = hash;
      return hash;
    }

    public static com.google.privacy.dlp.v2beta1.PrivacyMetric.NumericalStatsConfig parseFrom(
        java.nio.ByteBuffer data)
        throws com.google.protobuf.InvalidProtocolBufferException {
      return PARSER.parseFrom(data);
    }
    public static com.google.privacy.dlp.v2beta1.PrivacyMetric.NumericalStatsConfig parseFrom(
        java.nio.ByteBuffer data,
        com.google.protobuf.ExtensionRegistryLite extensionRegistry)
        throws com.google.protobuf.InvalidProtocolBufferException {
      return PARSER.parseFrom(data, extensionRegistry);
    }
    public static com.google.privacy.dlp.v2beta1.PrivacyMetric.NumericalStatsConfig parseFrom(
        com.google.protobuf.ByteString data)
        throws com.google.protobuf.InvalidProtocolBufferException {
      return PARSER.parseFrom(data);
    }
    public static com.google.privacy.dlp.v2beta1.PrivacyMetric.NumericalStatsConfig 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.privacy.dlp.v2beta1.PrivacyMetric.NumericalStatsConfig parseFrom(byte[] data)
        throws com.google.protobuf.InvalidProtocolBufferException {
      return PARSER.parseFrom(data);
    }
    public static com.google.privacy.dlp.v2beta1.PrivacyMetric.NumericalStatsConfig parseFrom(
        byte[] data,
        com.google.protobuf.ExtensionRegistryLite extensionRegistry)
        throws com.google.protobuf.InvalidProtocolBufferException {
      return PARSER.parseFrom(data, extensionRegistry);
    }
    public static com.google.privacy.dlp.v2beta1.PrivacyMetric.NumericalStatsConfig parseFrom(java.io.InputStream input)
        throws java.io.IOException {
      return com.google.protobuf.GeneratedMessageV3
          .parseWithIOException(PARSER, input);
    }
    public static com.google.privacy.dlp.v2beta1.PrivacyMetric.NumericalStatsConfig 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.privacy.dlp.v2beta1.PrivacyMetric.NumericalStatsConfig parseDelimitedFrom(java.io.InputStream input)
        throws java.io.IOException {
      return com.google.protobuf.GeneratedMessageV3
          .parseDelimitedWithIOException(PARSER, input);
    }
    public static com.google.privacy.dlp.v2beta1.PrivacyMetric.NumericalStatsConfig 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.privacy.dlp.v2beta1.PrivacyMetric.NumericalStatsConfig parseFrom(
        com.google.protobuf.CodedInputStream input)
        throws java.io.IOException {
      return com.google.protobuf.GeneratedMessageV3
          .parseWithIOException(PARSER, input);
    }
    public static com.google.privacy.dlp.v2beta1.PrivacyMetric.NumericalStatsConfig parseFrom(
        com.google.protobuf.CodedInputStream input,
        com.google.protobuf.ExtensionRegistryLite extensionRegistry)
        throws java.io.IOException {
      return com.google.protobuf.GeneratedMessageV3
          .parseWithIOException(PARSER, input, extensionRegistry);
    }

    public Builder newBuilderForType() { return newBuilder(); }
    public static Builder newBuilder() {
      return DEFAULT_INSTANCE.toBuilder();
    }
    public static Builder newBuilder(com.google.privacy.dlp.v2beta1.PrivacyMetric.NumericalStatsConfig prototype) {
      return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype);
    }
    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>
     * Compute numerical stats over an individual column, including
     * min, max, and quantiles.
     * </pre>
     *
     * Protobuf type {@code google.privacy.dlp.v2beta1.PrivacyMetric.NumericalStatsConfig}
     */
    public static final class Builder extends
        com.google.protobuf.GeneratedMessageV3.Builder<Builder> implements
        // @@protoc_insertion_point(builder_implements:google.privacy.dlp.v2beta1.PrivacyMetric.NumericalStatsConfig)
        com.google.privacy.dlp.v2beta1.PrivacyMetric.NumericalStatsConfigOrBuilder {
      public static final com.google.protobuf.Descriptors.Descriptor
          getDescriptor() {
        return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_PrivacyMetric_NumericalStatsConfig_descriptor;
      }

      protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
          internalGetFieldAccessorTable() {
        return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_PrivacyMetric_NumericalStatsConfig_fieldAccessorTable
            .ensureFieldAccessorsInitialized(
                com.google.privacy.dlp.v2beta1.PrivacyMetric.NumericalStatsConfig.class, com.google.privacy.dlp.v2beta1.PrivacyMetric.NumericalStatsConfig.Builder.class);
      }

      // Construct using com.google.privacy.dlp.v2beta1.PrivacyMetric.NumericalStatsConfig.newBuilder()
      private Builder() {
        maybeForceBuilderInitialization();
      }

      private Builder(
          com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
        super(parent);
        maybeForceBuilderInitialization();
      }
      private void maybeForceBuilderInitialization() {
        if (com.google.protobuf.GeneratedMessageV3
                .alwaysUseFieldBuilders) {
        }
      }
      public Builder clear() {
        super.clear();
        if (fieldBuilder_ == null) {
          field_ = null;
        } else {
          field_ = null;
          fieldBuilder_ = null;
        }
        return this;
      }

      public com.google.protobuf.Descriptors.Descriptor
          getDescriptorForType() {
        return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_PrivacyMetric_NumericalStatsConfig_descriptor;
      }

      public com.google.privacy.dlp.v2beta1.PrivacyMetric.NumericalStatsConfig getDefaultInstanceForType() {
        return com.google.privacy.dlp.v2beta1.PrivacyMetric.NumericalStatsConfig.getDefaultInstance();
      }

      public com.google.privacy.dlp.v2beta1.PrivacyMetric.NumericalStatsConfig build() {
        com.google.privacy.dlp.v2beta1.PrivacyMetric.NumericalStatsConfig result = buildPartial();
        if (!result.isInitialized()) {
          throw newUninitializedMessageException(result);
        }
        return result;
      }

      public com.google.privacy.dlp.v2beta1.PrivacyMetric.NumericalStatsConfig buildPartial() {
        com.google.privacy.dlp.v2beta1.PrivacyMetric.NumericalStatsConfig result = new com.google.privacy.dlp.v2beta1.PrivacyMetric.NumericalStatsConfig(this);
        if (fieldBuilder_ == null) {
          result.field_ = field_;
        } else {
          result.field_ = fieldBuilder_.build();
        }
        onBuilt();
        return result;
      }

      public Builder clone() {
        return (Builder) super.clone();
      }
      public Builder setField(
          com.google.protobuf.Descriptors.FieldDescriptor field,
          java.lang.Object value) {
        return (Builder) super.setField(field, value);
      }
      public Builder clearField(
          com.google.protobuf.Descriptors.FieldDescriptor field) {
        return (Builder) super.clearField(field);
      }
      public Builder clearOneof(
          com.google.protobuf.Descriptors.OneofDescriptor oneof) {
        return (Builder) super.clearOneof(oneof);
      }
      public Builder setRepeatedField(
          com.google.protobuf.Descriptors.FieldDescriptor field,
          int index, java.lang.Object value) {
        return (Builder) super.setRepeatedField(field, index, value);
      }
      public Builder addRepeatedField(
          com.google.protobuf.Descriptors.FieldDescriptor field,
          java.lang.Object value) {
        return (Builder) super.addRepeatedField(field, value);
      }
      public Builder mergeFrom(com.google.protobuf.Message other) {
        if (other instanceof com.google.privacy.dlp.v2beta1.PrivacyMetric.NumericalStatsConfig) {
          return mergeFrom((com.google.privacy.dlp.v2beta1.PrivacyMetric.NumericalStatsConfig)other);
        } else {
          super.mergeFrom(other);
          return this;
        }
      }

      public Builder mergeFrom(com.google.privacy.dlp.v2beta1.PrivacyMetric.NumericalStatsConfig other) {
        if (other == com.google.privacy.dlp.v2beta1.PrivacyMetric.NumericalStatsConfig.getDefaultInstance()) return this;
        if (other.hasField()) {
          mergeField(other.getField());
        }
        this.mergeUnknownFields(other.unknownFields);
        onChanged();
        return this;
      }

      public final boolean isInitialized() {
        return true;
      }

      public Builder mergeFrom(
          com.google.protobuf.CodedInputStream input,
          com.google.protobuf.ExtensionRegistryLite extensionRegistry)
          throws java.io.IOException {
        com.google.privacy.dlp.v2beta1.PrivacyMetric.NumericalStatsConfig parsedMessage = null;
        try {
          parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry);
        } catch (com.google.protobuf.InvalidProtocolBufferException e) {
          parsedMessage = (com.google.privacy.dlp.v2beta1.PrivacyMetric.NumericalStatsConfig) e.getUnfinishedMessage();
          throw e.unwrapIOException();
        } finally {
          if (parsedMessage != null) {
            mergeFrom(parsedMessage);
          }
        }
        return this;
      }

      private com.google.privacy.dlp.v2beta1.FieldId field_ = null;
      private com.google.protobuf.SingleFieldBuilderV3<
          com.google.privacy.dlp.v2beta1.FieldId, com.google.privacy.dlp.v2beta1.FieldId.Builder, com.google.privacy.dlp.v2beta1.FieldIdOrBuilder> fieldBuilder_;
      /**
       * <pre>
       * Field to compute numerical stats on. Supported types are
       * integer, float, date, datetime, timestamp, time.
       * </pre>
       *
       * <code>.google.privacy.dlp.v2beta1.FieldId field = 1;</code>
       */
      public boolean hasField() {
        return fieldBuilder_ != null || field_ != null;
      }
      /**
       * <pre>
       * Field to compute numerical stats on. Supported types are
       * integer, float, date, datetime, timestamp, time.
       * </pre>
       *
       * <code>.google.privacy.dlp.v2beta1.FieldId field = 1;</code>
       */
      public com.google.privacy.dlp.v2beta1.FieldId getField() {
        if (fieldBuilder_ == null) {
          return field_ == null ? com.google.privacy.dlp.v2beta1.FieldId.getDefaultInstance() : field_;
        } else {
          return fieldBuilder_.getMessage();
        }
      }
      /**
       * <pre>
       * Field to compute numerical stats on. Supported types are
       * integer, float, date, datetime, timestamp, time.
       * </pre>
       *
       * <code>.google.privacy.dlp.v2beta1.FieldId field = 1;</code>
       */
      public Builder setField(com.google.privacy.dlp.v2beta1.FieldId value) {
        if (fieldBuilder_ == null) {
          if (value == null) {
            throw new NullPointerException();
          }
          field_ = value;
          onChanged();
        } else {
          fieldBuilder_.setMessage(value);
        }

        return this;
      }
      /**
       * <pre>
       * Field to compute numerical stats on. Supported types are
       * integer, float, date, datetime, timestamp, time.
       * </pre>
       *
       * <code>.google.privacy.dlp.v2beta1.FieldId field = 1;</code>
       */
      public Builder setField(
          com.google.privacy.dlp.v2beta1.FieldId.Builder builderForValue) {
        if (fieldBuilder_ == null) {
          field_ = builderForValue.build();
          onChanged();
        } else {
          fieldBuilder_.setMessage(builderForValue.build());
        }

        return this;
      }
      /**
       * <pre>
       * Field to compute numerical stats on. Supported types are
       * integer, float, date, datetime, timestamp, time.
       * </pre>
       *
       * <code>.google.privacy.dlp.v2beta1.FieldId field = 1;</code>
       */
      public Builder mergeField(com.google.privacy.dlp.v2beta1.FieldId value) {
        if (fieldBuilder_ == null) {
          if (field_ != null) {
            field_ =
              com.google.privacy.dlp.v2beta1.FieldId.newBuilder(field_).mergeFrom(value).buildPartial();
          } else {
            field_ = value;
          }
          onChanged();
        } else {
          fieldBuilder_.mergeFrom(value);
        }

        return this;
      }
      /**
       * <pre>
       * Field to compute numerical stats on. Supported types are
       * integer, float, date, datetime, timestamp, time.
       * </pre>
       *
       * <code>.google.privacy.dlp.v2beta1.FieldId field = 1;</code>
       */
      public Builder clearField() {
        if (fieldBuilder_ == null) {
          field_ = null;
          onChanged();
        } else {
          field_ = null;
          fieldBuilder_ = null;
        }

        return this;
      }
      /**
       * <pre>
       * Field to compute numerical stats on. Supported types are
       * integer, float, date, datetime, timestamp, time.
       * </pre>
       *
       * <code>.google.privacy.dlp.v2beta1.FieldId field = 1;</code>
       */
      public com.google.privacy.dlp.v2beta1.FieldId.Builder getFieldBuilder() {
        
        onChanged();
        return getFieldFieldBuilder().getBuilder();
      }
      /**
       * <pre>
       * Field to compute numerical stats on. Supported types are
       * integer, float, date, datetime, timestamp, time.
       * </pre>
       *
       * <code>.google.privacy.dlp.v2beta1.FieldId field = 1;</code>
       */
      public com.google.privacy.dlp.v2beta1.FieldIdOrBuilder getFieldOrBuilder() {
        if (fieldBuilder_ != null) {
          return fieldBuilder_.getMessageOrBuilder();
        } else {
          return field_ == null ?
              com.google.privacy.dlp.v2beta1.FieldId.getDefaultInstance() : field_;
        }
      }
      /**
       * <pre>
       * Field to compute numerical stats on. Supported types are
       * integer, float, date, datetime, timestamp, time.
       * </pre>
       *
       * <code>.google.privacy.dlp.v2beta1.FieldId field = 1;</code>
       */
      private com.google.protobuf.SingleFieldBuilderV3<
          com.google.privacy.dlp.v2beta1.FieldId, com.google.privacy.dlp.v2beta1.FieldId.Builder, com.google.privacy.dlp.v2beta1.FieldIdOrBuilder> 
          getFieldFieldBuilder() {
        if (fieldBuilder_ == null) {
          fieldBuilder_ = new com.google.protobuf.SingleFieldBuilderV3<
              com.google.privacy.dlp.v2beta1.FieldId, com.google.privacy.dlp.v2beta1.FieldId.Builder, com.google.privacy.dlp.v2beta1.FieldIdOrBuilder>(
                  getField(),
                  getParentForChildren(),
                  isClean());
          field_ = null;
        }
        return fieldBuilder_;
      }
      public final Builder setUnknownFields(
          final com.google.protobuf.UnknownFieldSet unknownFields) {
        return super.setUnknownFieldsProto3(unknownFields);
      }

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


      // @@protoc_insertion_point(builder_scope:google.privacy.dlp.v2beta1.PrivacyMetric.NumericalStatsConfig)
    }

    // @@protoc_insertion_point(class_scope:google.privacy.dlp.v2beta1.PrivacyMetric.NumericalStatsConfig)
    private static final com.google.privacy.dlp.v2beta1.PrivacyMetric.NumericalStatsConfig DEFAULT_INSTANCE;
    static {
      DEFAULT_INSTANCE = new com.google.privacy.dlp.v2beta1.PrivacyMetric.NumericalStatsConfig();
    }

    public static com.google.privacy.dlp.v2beta1.PrivacyMetric.NumericalStatsConfig getDefaultInstance() {
      return DEFAULT_INSTANCE;
    }

    private static final com.google.protobuf.Parser<NumericalStatsConfig>
        PARSER = new com.google.protobuf.AbstractParser<NumericalStatsConfig>() {
      public NumericalStatsConfig parsePartialFrom(
          com.google.protobuf.CodedInputStream input,
          com.google.protobuf.ExtensionRegistryLite extensionRegistry)
          throws com.google.protobuf.InvalidProtocolBufferException {
        return new NumericalStatsConfig(input, extensionRegistry);
      }
    };

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

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

    public com.google.privacy.dlp.v2beta1.PrivacyMetric.NumericalStatsConfig getDefaultInstanceForType() {
      return DEFAULT_INSTANCE;
    }

  }

  public interface CategoricalStatsConfigOrBuilder extends
      // @@protoc_insertion_point(interface_extends:google.privacy.dlp.v2beta1.PrivacyMetric.CategoricalStatsConfig)
      com.google.protobuf.MessageOrBuilder {

    /**
     * <pre>
     * Field to compute categorical stats on. All column types are
     * supported except for arrays and structs. However, it may be more
     * informative to use NumericalStats when the field type is supported,
     * depending on the data.
     * </pre>
     *
     * <code>.google.privacy.dlp.v2beta1.FieldId field = 1;</code>
     */
    boolean hasField();
    /**
     * <pre>
     * Field to compute categorical stats on. All column types are
     * supported except for arrays and structs. However, it may be more
     * informative to use NumericalStats when the field type is supported,
     * depending on the data.
     * </pre>
     *
     * <code>.google.privacy.dlp.v2beta1.FieldId field = 1;</code>
     */
    com.google.privacy.dlp.v2beta1.FieldId getField();
    /**
     * <pre>
     * Field to compute categorical stats on. All column types are
     * supported except for arrays and structs. However, it may be more
     * informative to use NumericalStats when the field type is supported,
     * depending on the data.
     * </pre>
     *
     * <code>.google.privacy.dlp.v2beta1.FieldId field = 1;</code>
     */
    com.google.privacy.dlp.v2beta1.FieldIdOrBuilder getFieldOrBuilder();
  }
  /**
   * <pre>
   * Compute numerical stats over an individual column, including
   * number of distinct values and value count distribution.
   * </pre>
   *
   * Protobuf type {@code google.privacy.dlp.v2beta1.PrivacyMetric.CategoricalStatsConfig}
   */
  public  static final class CategoricalStatsConfig extends
      com.google.protobuf.GeneratedMessageV3 implements
      // @@protoc_insertion_point(message_implements:google.privacy.dlp.v2beta1.PrivacyMetric.CategoricalStatsConfig)
      CategoricalStatsConfigOrBuilder {
  private static final long serialVersionUID = 0L;
    // Use CategoricalStatsConfig.newBuilder() to construct.
    private CategoricalStatsConfig(com.google.protobuf.GeneratedMessageV3.Builder<?> builder) {
      super(builder);
    }
    private CategoricalStatsConfig() {
    }

    @java.lang.Override
    public final com.google.protobuf.UnknownFieldSet
    getUnknownFields() {
      return this.unknownFields;
    }
    private CategoricalStatsConfig(
        com.google.protobuf.CodedInputStream input,
        com.google.protobuf.ExtensionRegistryLite extensionRegistry)
        throws com.google.protobuf.InvalidProtocolBufferException {
      this();
      if (extensionRegistry == null) {
        throw new java.lang.NullPointerException();
      }
      int mutable_bitField0_ = 0;
      com.google.protobuf.UnknownFieldSet.Builder unknownFields =
          com.google.protobuf.UnknownFieldSet.newBuilder();
      try {
        boolean done = false;
        while (!done) {
          int tag = input.readTag();
          switch (tag) {
            case 0:
              done = true;
              break;
            default: {
              if (!parseUnknownFieldProto3(
                  input, unknownFields, extensionRegistry, tag)) {
                done = true;
              }
              break;
            }
            case 10: {
              com.google.privacy.dlp.v2beta1.FieldId.Builder subBuilder = null;
              if (field_ != null) {
                subBuilder = field_.toBuilder();
              }
              field_ = input.readMessage(com.google.privacy.dlp.v2beta1.FieldId.parser(), extensionRegistry);
              if (subBuilder != null) {
                subBuilder.mergeFrom(field_);
                field_ = subBuilder.buildPartial();
              }

              break;
            }
          }
        }
      } catch (com.google.protobuf.InvalidProtocolBufferException e) {
        throw e.setUnfinishedMessage(this);
      } catch (java.io.IOException e) {
        throw new com.google.protobuf.InvalidProtocolBufferException(
            e).setUnfinishedMessage(this);
      } finally {
        this.unknownFields = unknownFields.build();
        makeExtensionsImmutable();
      }
    }
    public static final com.google.protobuf.Descriptors.Descriptor
        getDescriptor() {
      return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_PrivacyMetric_CategoricalStatsConfig_descriptor;
    }

    protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
        internalGetFieldAccessorTable() {
      return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_PrivacyMetric_CategoricalStatsConfig_fieldAccessorTable
          .ensureFieldAccessorsInitialized(
              com.google.privacy.dlp.v2beta1.PrivacyMetric.CategoricalStatsConfig.class, com.google.privacy.dlp.v2beta1.PrivacyMetric.CategoricalStatsConfig.Builder.class);
    }

    public static final int FIELD_FIELD_NUMBER = 1;
    private com.google.privacy.dlp.v2beta1.FieldId field_;
    /**
     * <pre>
     * Field to compute categorical stats on. All column types are
     * supported except for arrays and structs. However, it may be more
     * informative to use NumericalStats when the field type is supported,
     * depending on the data.
     * </pre>
     *
     * <code>.google.privacy.dlp.v2beta1.FieldId field = 1;</code>
     */
    public boolean hasField() {
      return field_ != null;
    }
    /**
     * <pre>
     * Field to compute categorical stats on. All column types are
     * supported except for arrays and structs. However, it may be more
     * informative to use NumericalStats when the field type is supported,
     * depending on the data.
     * </pre>
     *
     * <code>.google.privacy.dlp.v2beta1.FieldId field = 1;</code>
     */
    public com.google.privacy.dlp.v2beta1.FieldId getField() {
      return field_ == null ? com.google.privacy.dlp.v2beta1.FieldId.getDefaultInstance() : field_;
    }
    /**
     * <pre>
     * Field to compute categorical stats on. All column types are
     * supported except for arrays and structs. However, it may be more
     * informative to use NumericalStats when the field type is supported,
     * depending on the data.
     * </pre>
     *
     * <code>.google.privacy.dlp.v2beta1.FieldId field = 1;</code>
     */
    public com.google.privacy.dlp.v2beta1.FieldIdOrBuilder getFieldOrBuilder() {
      return getField();
    }

    private byte memoizedIsInitialized = -1;
    public final boolean isInitialized() {
      byte isInitialized = memoizedIsInitialized;
      if (isInitialized == 1) return true;
      if (isInitialized == 0) return false;

      memoizedIsInitialized = 1;
      return true;
    }

    public void writeTo(com.google.protobuf.CodedOutputStream output)
                        throws java.io.IOException {
      if (field_ != null) {
        output.writeMessage(1, getField());
      }
      unknownFields.writeTo(output);
    }

    public int getSerializedSize() {
      int size = memoizedSize;
      if (size != -1) return size;

      size = 0;
      if (field_ != null) {
        size += com.google.protobuf.CodedOutputStream
          .computeMessageSize(1, getField());
      }
      size += unknownFields.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.privacy.dlp.v2beta1.PrivacyMetric.CategoricalStatsConfig)) {
        return super.equals(obj);
      }
      com.google.privacy.dlp.v2beta1.PrivacyMetric.CategoricalStatsConfig other = (com.google.privacy.dlp.v2beta1.PrivacyMetric.CategoricalStatsConfig) obj;

      boolean result = true;
      result = result && (hasField() == other.hasField());
      if (hasField()) {
        result = result && getField()
            .equals(other.getField());
      }
      result = result && unknownFields.equals(other.unknownFields);
      return result;
    }

    @java.lang.Override
    public int hashCode() {
      if (memoizedHashCode != 0) {
        return memoizedHashCode;
      }
      int hash = 41;
      hash = (19 * hash) + getDescriptor().hashCode();
      if (hasField()) {
        hash = (37 * hash) + FIELD_FIELD_NUMBER;
        hash = (53 * hash) + getField().hashCode();
      }
      hash = (29 * hash) + unknownFields.hashCode();
      memoizedHashCode = hash;
      return hash;
    }

    public static com.google.privacy.dlp.v2beta1.PrivacyMetric.CategoricalStatsConfig parseFrom(
        java.nio.ByteBuffer data)
        throws com.google.protobuf.InvalidProtocolBufferException {
      return PARSER.parseFrom(data);
    }
    public static com.google.privacy.dlp.v2beta1.PrivacyMetric.CategoricalStatsConfig parseFrom(
        java.nio.ByteBuffer data,
        com.google.protobuf.ExtensionRegistryLite extensionRegistry)
        throws com.google.protobuf.InvalidProtocolBufferException {
      return PARSER.parseFrom(data, extensionRegistry);
    }
    public static com.google.privacy.dlp.v2beta1.PrivacyMetric.CategoricalStatsConfig parseFrom(
        com.google.protobuf.ByteString data)
        throws com.google.protobuf.InvalidProtocolBufferException {
      return PARSER.parseFrom(data);
    }
    public static com.google.privacy.dlp.v2beta1.PrivacyMetric.CategoricalStatsConfig 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.privacy.dlp.v2beta1.PrivacyMetric.CategoricalStatsConfig parseFrom(byte[] data)
        throws com.google.protobuf.InvalidProtocolBufferException {
      return PARSER.parseFrom(data);
    }
    public static com.google.privacy.dlp.v2beta1.PrivacyMetric.CategoricalStatsConfig parseFrom(
        byte[] data,
        com.google.protobuf.ExtensionRegistryLite extensionRegistry)
        throws com.google.protobuf.InvalidProtocolBufferException {
      return PARSER.parseFrom(data, extensionRegistry);
    }
    public static com.google.privacy.dlp.v2beta1.PrivacyMetric.CategoricalStatsConfig parseFrom(java.io.InputStream input)
        throws java.io.IOException {
      return com.google.protobuf.GeneratedMessageV3
          .parseWithIOException(PARSER, input);
    }
    public static com.google.privacy.dlp.v2beta1.PrivacyMetric.CategoricalStatsConfig 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.privacy.dlp.v2beta1.PrivacyMetric.CategoricalStatsConfig parseDelimitedFrom(java.io.InputStream input)
        throws java.io.IOException {
      return com.google.protobuf.GeneratedMessageV3
          .parseDelimitedWithIOException(PARSER, input);
    }
    public static com.google.privacy.dlp.v2beta1.PrivacyMetric.CategoricalStatsConfig 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.privacy.dlp.v2beta1.PrivacyMetric.CategoricalStatsConfig parseFrom(
        com.google.protobuf.CodedInputStream input)
        throws java.io.IOException {
      return com.google.protobuf.GeneratedMessageV3
          .parseWithIOException(PARSER, input);
    }
    public static com.google.privacy.dlp.v2beta1.PrivacyMetric.CategoricalStatsConfig parseFrom(
        com.google.protobuf.CodedInputStream input,
        com.google.protobuf.ExtensionRegistryLite extensionRegistry)
        throws java.io.IOException {
      return com.google.protobuf.GeneratedMessageV3
          .parseWithIOException(PARSER, input, extensionRegistry);
    }

    public Builder newBuilderForType() { return newBuilder(); }
    public static Builder newBuilder() {
      return DEFAULT_INSTANCE.toBuilder();
    }
    public static Builder newBuilder(com.google.privacy.dlp.v2beta1.PrivacyMetric.CategoricalStatsConfig prototype) {
      return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype);
    }
    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>
     * Compute numerical stats over an individual column, including
     * number of distinct values and value count distribution.
     * </pre>
     *
     * Protobuf type {@code google.privacy.dlp.v2beta1.PrivacyMetric.CategoricalStatsConfig}
     */
    public static final class Builder extends
        com.google.protobuf.GeneratedMessageV3.Builder<Builder> implements
        // @@protoc_insertion_point(builder_implements:google.privacy.dlp.v2beta1.PrivacyMetric.CategoricalStatsConfig)
        com.google.privacy.dlp.v2beta1.PrivacyMetric.CategoricalStatsConfigOrBuilder {
      public static final com.google.protobuf.Descriptors.Descriptor
          getDescriptor() {
        return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_PrivacyMetric_CategoricalStatsConfig_descriptor;
      }

      protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
          internalGetFieldAccessorTable() {
        return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_PrivacyMetric_CategoricalStatsConfig_fieldAccessorTable
            .ensureFieldAccessorsInitialized(
                com.google.privacy.dlp.v2beta1.PrivacyMetric.CategoricalStatsConfig.class, com.google.privacy.dlp.v2beta1.PrivacyMetric.CategoricalStatsConfig.Builder.class);
      }

      // Construct using com.google.privacy.dlp.v2beta1.PrivacyMetric.CategoricalStatsConfig.newBuilder()
      private Builder() {
        maybeForceBuilderInitialization();
      }

      private Builder(
          com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
        super(parent);
        maybeForceBuilderInitialization();
      }
      private void maybeForceBuilderInitialization() {
        if (com.google.protobuf.GeneratedMessageV3
                .alwaysUseFieldBuilders) {
        }
      }
      public Builder clear() {
        super.clear();
        if (fieldBuilder_ == null) {
          field_ = null;
        } else {
          field_ = null;
          fieldBuilder_ = null;
        }
        return this;
      }

      public com.google.protobuf.Descriptors.Descriptor
          getDescriptorForType() {
        return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_PrivacyMetric_CategoricalStatsConfig_descriptor;
      }

      public com.google.privacy.dlp.v2beta1.PrivacyMetric.CategoricalStatsConfig getDefaultInstanceForType() {
        return com.google.privacy.dlp.v2beta1.PrivacyMetric.CategoricalStatsConfig.getDefaultInstance();
      }

      public com.google.privacy.dlp.v2beta1.PrivacyMetric.CategoricalStatsConfig build() {
        com.google.privacy.dlp.v2beta1.PrivacyMetric.CategoricalStatsConfig result = buildPartial();
        if (!result.isInitialized()) {
          throw newUninitializedMessageException(result);
        }
        return result;
      }

      public com.google.privacy.dlp.v2beta1.PrivacyMetric.CategoricalStatsConfig buildPartial() {
        com.google.privacy.dlp.v2beta1.PrivacyMetric.CategoricalStatsConfig result = new com.google.privacy.dlp.v2beta1.PrivacyMetric.CategoricalStatsConfig(this);
        if (fieldBuilder_ == null) {
          result.field_ = field_;
        } else {
          result.field_ = fieldBuilder_.build();
        }
        onBuilt();
        return result;
      }

      public Builder clone() {
        return (Builder) super.clone();
      }
      public Builder setField(
          com.google.protobuf.Descriptors.FieldDescriptor field,
          java.lang.Object value) {
        return (Builder) super.setField(field, value);
      }
      public Builder clearField(
          com.google.protobuf.Descriptors.FieldDescriptor field) {
        return (Builder) super.clearField(field);
      }
      public Builder clearOneof(
          com.google.protobuf.Descriptors.OneofDescriptor oneof) {
        return (Builder) super.clearOneof(oneof);
      }
      public Builder setRepeatedField(
          com.google.protobuf.Descriptors.FieldDescriptor field,
          int index, java.lang.Object value) {
        return (Builder) super.setRepeatedField(field, index, value);
      }
      public Builder addRepeatedField(
          com.google.protobuf.Descriptors.FieldDescriptor field,
          java.lang.Object value) {
        return (Builder) super.addRepeatedField(field, value);
      }
      public Builder mergeFrom(com.google.protobuf.Message other) {
        if (other instanceof com.google.privacy.dlp.v2beta1.PrivacyMetric.CategoricalStatsConfig) {
          return mergeFrom((com.google.privacy.dlp.v2beta1.PrivacyMetric.CategoricalStatsConfig)other);
        } else {
          super.mergeFrom(other);
          return this;
        }
      }

      public Builder mergeFrom(com.google.privacy.dlp.v2beta1.PrivacyMetric.CategoricalStatsConfig other) {
        if (other == com.google.privacy.dlp.v2beta1.PrivacyMetric.CategoricalStatsConfig.getDefaultInstance()) return this;
        if (other.hasField()) {
          mergeField(other.getField());
        }
        this.mergeUnknownFields(other.unknownFields);
        onChanged();
        return this;
      }

      public final boolean isInitialized() {
        return true;
      }

      public Builder mergeFrom(
          com.google.protobuf.CodedInputStream input,
          com.google.protobuf.ExtensionRegistryLite extensionRegistry)
          throws java.io.IOException {
        com.google.privacy.dlp.v2beta1.PrivacyMetric.CategoricalStatsConfig parsedMessage = null;
        try {
          parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry);
        } catch (com.google.protobuf.InvalidProtocolBufferException e) {
          parsedMessage = (com.google.privacy.dlp.v2beta1.PrivacyMetric.CategoricalStatsConfig) e.getUnfinishedMessage();
          throw e.unwrapIOException();
        } finally {
          if (parsedMessage != null) {
            mergeFrom(parsedMessage);
          }
        }
        return this;
      }

      private com.google.privacy.dlp.v2beta1.FieldId field_ = null;
      private com.google.protobuf.SingleFieldBuilderV3<
          com.google.privacy.dlp.v2beta1.FieldId, com.google.privacy.dlp.v2beta1.FieldId.Builder, com.google.privacy.dlp.v2beta1.FieldIdOrBuilder> fieldBuilder_;
      /**
       * <pre>
       * Field to compute categorical stats on. All column types are
       * supported except for arrays and structs. However, it may be more
       * informative to use NumericalStats when the field type is supported,
       * depending on the data.
       * </pre>
       *
       * <code>.google.privacy.dlp.v2beta1.FieldId field = 1;</code>
       */
      public boolean hasField() {
        return fieldBuilder_ != null || field_ != null;
      }
      /**
       * <pre>
       * Field to compute categorical stats on. All column types are
       * supported except for arrays and structs. However, it may be more
       * informative to use NumericalStats when the field type is supported,
       * depending on the data.
       * </pre>
       *
       * <code>.google.privacy.dlp.v2beta1.FieldId field = 1;</code>
       */
      public com.google.privacy.dlp.v2beta1.FieldId getField() {
        if (fieldBuilder_ == null) {
          return field_ == null ? com.google.privacy.dlp.v2beta1.FieldId.getDefaultInstance() : field_;
        } else {
          return fieldBuilder_.getMessage();
        }
      }
      /**
       * <pre>
       * Field to compute categorical stats on. All column types are
       * supported except for arrays and structs. However, it may be more
       * informative to use NumericalStats when the field type is supported,
       * depending on the data.
       * </pre>
       *
       * <code>.google.privacy.dlp.v2beta1.FieldId field = 1;</code>
       */
      public Builder setField(com.google.privacy.dlp.v2beta1.FieldId value) {
        if (fieldBuilder_ == null) {
          if (value == null) {
            throw new NullPointerException();
          }
          field_ = value;
          onChanged();
        } else {
          fieldBuilder_.setMessage(value);
        }

        return this;
      }
      /**
       * <pre>
       * Field to compute categorical stats on. All column types are
       * supported except for arrays and structs. However, it may be more
       * informative to use NumericalStats when the field type is supported,
       * depending on the data.
       * </pre>
       *
       * <code>.google.privacy.dlp.v2beta1.FieldId field = 1;</code>
       */
      public Builder setField(
          com.google.privacy.dlp.v2beta1.FieldId.Builder builderForValue) {
        if (fieldBuilder_ == null) {
          field_ = builderForValue.build();
          onChanged();
        } else {
          fieldBuilder_.setMessage(builderForValue.build());
        }

        return this;
      }
      /**
       * <pre>
       * Field to compute categorical stats on. All column types are
       * supported except for arrays and structs. However, it may be more
       * informative to use NumericalStats when the field type is supported,
       * depending on the data.
       * </pre>
       *
       * <code>.google.privacy.dlp.v2beta1.FieldId field = 1;</code>
       */
      public Builder mergeField(com.google.privacy.dlp.v2beta1.FieldId value) {
        if (fieldBuilder_ == null) {
          if (field_ != null) {
            field_ =
              com.google.privacy.dlp.v2beta1.FieldId.newBuilder(field_).mergeFrom(value).buildPartial();
          } else {
            field_ = value;
          }
          onChanged();
        } else {
          fieldBuilder_.mergeFrom(value);
        }

        return this;
      }
      /**
       * <pre>
       * Field to compute categorical stats on. All column types are
       * supported except for arrays and structs. However, it may be more
       * informative to use NumericalStats when the field type is supported,
       * depending on the data.
       * </pre>
       *
       * <code>.google.privacy.dlp.v2beta1.FieldId field = 1;</code>
       */
      public Builder clearField() {
        if (fieldBuilder_ == null) {
          field_ = null;
          onChanged();
        } else {
          field_ = null;
          fieldBuilder_ = null;
        }

        return this;
      }
      /**
       * <pre>
       * Field to compute categorical stats on. All column types are
       * supported except for arrays and structs. However, it may be more
       * informative to use NumericalStats when the field type is supported,
       * depending on the data.
       * </pre>
       *
       * <code>.google.privacy.dlp.v2beta1.FieldId field = 1;</code>
       */
      public com.google.privacy.dlp.v2beta1.FieldId.Builder getFieldBuilder() {
        
        onChanged();
        return getFieldFieldBuilder().getBuilder();
      }
      /**
       * <pre>
       * Field to compute categorical stats on. All column types are
       * supported except for arrays and structs. However, it may be more
       * informative to use NumericalStats when the field type is supported,
       * depending on the data.
       * </pre>
       *
       * <code>.google.privacy.dlp.v2beta1.FieldId field = 1;</code>
       */
      public com.google.privacy.dlp.v2beta1.FieldIdOrBuilder getFieldOrBuilder() {
        if (fieldBuilder_ != null) {
          return fieldBuilder_.getMessageOrBuilder();
        } else {
          return field_ == null ?
              com.google.privacy.dlp.v2beta1.FieldId.getDefaultInstance() : field_;
        }
      }
      /**
       * <pre>
       * Field to compute categorical stats on. All column types are
       * supported except for arrays and structs. However, it may be more
       * informative to use NumericalStats when the field type is supported,
       * depending on the data.
       * </pre>
       *
       * <code>.google.privacy.dlp.v2beta1.FieldId field = 1;</code>
       */
      private com.google.protobuf.SingleFieldBuilderV3<
          com.google.privacy.dlp.v2beta1.FieldId, com.google.privacy.dlp.v2beta1.FieldId.Builder, com.google.privacy.dlp.v2beta1.FieldIdOrBuilder> 
          getFieldFieldBuilder() {
        if (fieldBuilder_ == null) {
          fieldBuilder_ = new com.google.protobuf.SingleFieldBuilderV3<
              com.google.privacy.dlp.v2beta1.FieldId, com.google.privacy.dlp.v2beta1.FieldId.Builder, com.google.privacy.dlp.v2beta1.FieldIdOrBuilder>(
                  getField(),
                  getParentForChildren(),
                  isClean());
          field_ = null;
        }
        return fieldBuilder_;
      }
      public final Builder setUnknownFields(
          final com.google.protobuf.UnknownFieldSet unknownFields) {
        return super.setUnknownFieldsProto3(unknownFields);
      }

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


      // @@protoc_insertion_point(builder_scope:google.privacy.dlp.v2beta1.PrivacyMetric.CategoricalStatsConfig)
    }

    // @@protoc_insertion_point(class_scope:google.privacy.dlp.v2beta1.PrivacyMetric.CategoricalStatsConfig)
    private static final com.google.privacy.dlp.v2beta1.PrivacyMetric.CategoricalStatsConfig DEFAULT_INSTANCE;
    static {
      DEFAULT_INSTANCE = new com.google.privacy.dlp.v2beta1.PrivacyMetric.CategoricalStatsConfig();
    }

    public static com.google.privacy.dlp.v2beta1.PrivacyMetric.CategoricalStatsConfig getDefaultInstance() {
      return DEFAULT_INSTANCE;
    }

    private static final com.google.protobuf.Parser<CategoricalStatsConfig>
        PARSER = new com.google.protobuf.AbstractParser<CategoricalStatsConfig>() {
      public CategoricalStatsConfig parsePartialFrom(
          com.google.protobuf.CodedInputStream input,
          com.google.protobuf.ExtensionRegistryLite extensionRegistry)
          throws com.google.protobuf.InvalidProtocolBufferException {
        return new CategoricalStatsConfig(input, extensionRegistry);
      }
    };

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

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

    public com.google.privacy.dlp.v2beta1.PrivacyMetric.CategoricalStatsConfig getDefaultInstanceForType() {
      return DEFAULT_INSTANCE;
    }

  }

  public interface KAnonymityConfigOrBuilder extends
      // @@protoc_insertion_point(interface_extends:google.privacy.dlp.v2beta1.PrivacyMetric.KAnonymityConfig)
      com.google.protobuf.MessageOrBuilder {

    /**
     * <pre>
     * Set of fields to compute k-anonymity over. When multiple fields are
     * specified, they are considered a single composite key. Structs and
     * repeated data types are not supported; however, nested fields are
     * supported so long as they are not structs themselves or nested within
     * a repeated field.
     * </pre>
     *
     * <code>repeated .google.privacy.dlp.v2beta1.FieldId quasi_ids = 1;</code>
     */
    java.util.List<com.google.privacy.dlp.v2beta1.FieldId> 
        getQuasiIdsList();
    /**
     * <pre>
     * Set of fields to compute k-anonymity over. When multiple fields are
     * specified, they are considered a single composite key. Structs and
     * repeated data types are not supported; however, nested fields are
     * supported so long as they are not structs themselves or nested within
     * a repeated field.
     * </pre>
     *
     * <code>repeated .google.privacy.dlp.v2beta1.FieldId quasi_ids = 1;</code>
     */
    com.google.privacy.dlp.v2beta1.FieldId getQuasiIds(int index);
    /**
     * <pre>
     * Set of fields to compute k-anonymity over. When multiple fields are
     * specified, they are considered a single composite key. Structs and
     * repeated data types are not supported; however, nested fields are
     * supported so long as they are not structs themselves or nested within
     * a repeated field.
     * </pre>
     *
     * <code>repeated .google.privacy.dlp.v2beta1.FieldId quasi_ids = 1;</code>
     */
    int getQuasiIdsCount();
    /**
     * <pre>
     * Set of fields to compute k-anonymity over. When multiple fields are
     * specified, they are considered a single composite key. Structs and
     * repeated data types are not supported; however, nested fields are
     * supported so long as they are not structs themselves or nested within
     * a repeated field.
     * </pre>
     *
     * <code>repeated .google.privacy.dlp.v2beta1.FieldId quasi_ids = 1;</code>
     */
    java.util.List<? extends com.google.privacy.dlp.v2beta1.FieldIdOrBuilder> 
        getQuasiIdsOrBuilderList();
    /**
     * <pre>
     * Set of fields to compute k-anonymity over. When multiple fields are
     * specified, they are considered a single composite key. Structs and
     * repeated data types are not supported; however, nested fields are
     * supported so long as they are not structs themselves or nested within
     * a repeated field.
     * </pre>
     *
     * <code>repeated .google.privacy.dlp.v2beta1.FieldId quasi_ids = 1;</code>
     */
    com.google.privacy.dlp.v2beta1.FieldIdOrBuilder getQuasiIdsOrBuilder(
        int index);

    /**
     * <pre>
     * Optional message indicating that each distinct `EntityId` should not
     * contribute to the k-anonymity count more than once per equivalence class.
     * </pre>
     *
     * <code>.google.privacy.dlp.v2beta1.EntityId entity_id = 2;</code>
     */
    boolean hasEntityId();
    /**
     * <pre>
     * Optional message indicating that each distinct `EntityId` should not
     * contribute to the k-anonymity count more than once per equivalence class.
     * </pre>
     *
     * <code>.google.privacy.dlp.v2beta1.EntityId entity_id = 2;</code>
     */
    com.google.privacy.dlp.v2beta1.EntityId getEntityId();
    /**
     * <pre>
     * Optional message indicating that each distinct `EntityId` should not
     * contribute to the k-anonymity count more than once per equivalence class.
     * </pre>
     *
     * <code>.google.privacy.dlp.v2beta1.EntityId entity_id = 2;</code>
     */
    com.google.privacy.dlp.v2beta1.EntityIdOrBuilder getEntityIdOrBuilder();
  }
  /**
   * <pre>
   * k-anonymity metric, used for analysis of reidentification risk.
   * </pre>
   *
   * Protobuf type {@code google.privacy.dlp.v2beta1.PrivacyMetric.KAnonymityConfig}
   */
  public  static final class KAnonymityConfig extends
      com.google.protobuf.GeneratedMessageV3 implements
      // @@protoc_insertion_point(message_implements:google.privacy.dlp.v2beta1.PrivacyMetric.KAnonymityConfig)
      KAnonymityConfigOrBuilder {
  private static final long serialVersionUID = 0L;
    // Use KAnonymityConfig.newBuilder() to construct.
    private KAnonymityConfig(com.google.protobuf.GeneratedMessageV3.Builder<?> builder) {
      super(builder);
    }
    private KAnonymityConfig() {
      quasiIds_ = java.util.Collections.emptyList();
    }

    @java.lang.Override
    public final com.google.protobuf.UnknownFieldSet
    getUnknownFields() {
      return this.unknownFields;
    }
    private KAnonymityConfig(
        com.google.protobuf.CodedInputStream input,
        com.google.protobuf.ExtensionRegistryLite extensionRegistry)
        throws com.google.protobuf.InvalidProtocolBufferException {
      this();
      if (extensionRegistry == null) {
        throw new java.lang.NullPointerException();
      }
      int mutable_bitField0_ = 0;
      com.google.protobuf.UnknownFieldSet.Builder unknownFields =
          com.google.protobuf.UnknownFieldSet.newBuilder();
      try {
        boolean done = false;
        while (!done) {
          int tag = input.readTag();
          switch (tag) {
            case 0:
              done = true;
              break;
            default: {
              if (!parseUnknownFieldProto3(
                  input, unknownFields, extensionRegistry, tag)) {
                done = true;
              }
              break;
            }
            case 10: {
              if (!((mutable_bitField0_ & 0x00000001) == 0x00000001)) {
                quasiIds_ = new java.util.ArrayList<com.google.privacy.dlp.v2beta1.FieldId>();
                mutable_bitField0_ |= 0x00000001;
              }
              quasiIds_.add(
                  input.readMessage(com.google.privacy.dlp.v2beta1.FieldId.parser(), extensionRegistry));
              break;
            }
            case 18: {
              com.google.privacy.dlp.v2beta1.EntityId.Builder subBuilder = null;
              if (entityId_ != null) {
                subBuilder = entityId_.toBuilder();
              }
              entityId_ = input.readMessage(com.google.privacy.dlp.v2beta1.EntityId.parser(), extensionRegistry);
              if (subBuilder != null) {
                subBuilder.mergeFrom(entityId_);
                entityId_ = subBuilder.buildPartial();
              }

              break;
            }
          }
        }
      } catch (com.google.protobuf.InvalidProtocolBufferException e) {
        throw e.setUnfinishedMessage(this);
      } catch (java.io.IOException e) {
        throw new com.google.protobuf.InvalidProtocolBufferException(
            e).setUnfinishedMessage(this);
      } finally {
        if (((mutable_bitField0_ & 0x00000001) == 0x00000001)) {
          quasiIds_ = java.util.Collections.unmodifiableList(quasiIds_);
        }
        this.unknownFields = unknownFields.build();
        makeExtensionsImmutable();
      }
    }
    public static final com.google.protobuf.Descriptors.Descriptor
        getDescriptor() {
      return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_PrivacyMetric_KAnonymityConfig_descriptor;
    }

    protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
        internalGetFieldAccessorTable() {
      return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_PrivacyMetric_KAnonymityConfig_fieldAccessorTable
          .ensureFieldAccessorsInitialized(
              com.google.privacy.dlp.v2beta1.PrivacyMetric.KAnonymityConfig.class, com.google.privacy.dlp.v2beta1.PrivacyMetric.KAnonymityConfig.Builder.class);
    }

    private int bitField0_;
    public static final int QUASI_IDS_FIELD_NUMBER = 1;
    private java.util.List<com.google.privacy.dlp.v2beta1.FieldId> quasiIds_;
    /**
     * <pre>
     * Set of fields to compute k-anonymity over. When multiple fields are
     * specified, they are considered a single composite key. Structs and
     * repeated data types are not supported; however, nested fields are
     * supported so long as they are not structs themselves or nested within
     * a repeated field.
     * </pre>
     *
     * <code>repeated .google.privacy.dlp.v2beta1.FieldId quasi_ids = 1;</code>
     */
    public java.util.List<com.google.privacy.dlp.v2beta1.FieldId> getQuasiIdsList() {
      return quasiIds_;
    }
    /**
     * <pre>
     * Set of fields to compute k-anonymity over. When multiple fields are
     * specified, they are considered a single composite key. Structs and
     * repeated data types are not supported; however, nested fields are
     * supported so long as they are not structs themselves or nested within
     * a repeated field.
     * </pre>
     *
     * <code>repeated .google.privacy.dlp.v2beta1.FieldId quasi_ids = 1;</code>
     */
    public java.util.List<? extends com.google.privacy.dlp.v2beta1.FieldIdOrBuilder> 
        getQuasiIdsOrBuilderList() {
      return quasiIds_;
    }
    /**
     * <pre>
     * Set of fields to compute k-anonymity over. When multiple fields are
     * specified, they are considered a single composite key. Structs and
     * repeated data types are not supported; however, nested fields are
     * supported so long as they are not structs themselves or nested within
     * a repeated field.
     * </pre>
     *
     * <code>repeated .google.privacy.dlp.v2beta1.FieldId quasi_ids = 1;</code>
     */
    public int getQuasiIdsCount() {
      return quasiIds_.size();
    }
    /**
     * <pre>
     * Set of fields to compute k-anonymity over. When multiple fields are
     * specified, they are considered a single composite key. Structs and
     * repeated data types are not supported; however, nested fields are
     * supported so long as they are not structs themselves or nested within
     * a repeated field.
     * </pre>
     *
     * <code>repeated .google.privacy.dlp.v2beta1.FieldId quasi_ids = 1;</code>
     */
    public com.google.privacy.dlp.v2beta1.FieldId getQuasiIds(int index) {
      return quasiIds_.get(index);
    }
    /**
     * <pre>
     * Set of fields to compute k-anonymity over. When multiple fields are
     * specified, they are considered a single composite key. Structs and
     * repeated data types are not supported; however, nested fields are
     * supported so long as they are not structs themselves or nested within
     * a repeated field.
     * </pre>
     *
     * <code>repeated .google.privacy.dlp.v2beta1.FieldId quasi_ids = 1;</code>
     */
    public com.google.privacy.dlp.v2beta1.FieldIdOrBuilder getQuasiIdsOrBuilder(
        int index) {
      return quasiIds_.get(index);
    }

    public static final int ENTITY_ID_FIELD_NUMBER = 2;
    private com.google.privacy.dlp.v2beta1.EntityId entityId_;
    /**
     * <pre>
     * Optional message indicating that each distinct `EntityId` should not
     * contribute to the k-anonymity count more than once per equivalence class.
     * </pre>
     *
     * <code>.google.privacy.dlp.v2beta1.EntityId entity_id = 2;</code>
     */
    public boolean hasEntityId() {
      return entityId_ != null;
    }
    /**
     * <pre>
     * Optional message indicating that each distinct `EntityId` should not
     * contribute to the k-anonymity count more than once per equivalence class.
     * </pre>
     *
     * <code>.google.privacy.dlp.v2beta1.EntityId entity_id = 2;</code>
     */
    public com.google.privacy.dlp.v2beta1.EntityId getEntityId() {
      return entityId_ == null ? com.google.privacy.dlp.v2beta1.EntityId.getDefaultInstance() : entityId_;
    }
    /**
     * <pre>
     * Optional message indicating that each distinct `EntityId` should not
     * contribute to the k-anonymity count more than once per equivalence class.
     * </pre>
     *
     * <code>.google.privacy.dlp.v2beta1.EntityId entity_id = 2;</code>
     */
    public com.google.privacy.dlp.v2beta1.EntityIdOrBuilder getEntityIdOrBuilder() {
      return getEntityId();
    }

    private byte memoizedIsInitialized = -1;
    public final boolean isInitialized() {
      byte isInitialized = memoizedIsInitialized;
      if (isInitialized == 1) return true;
      if (isInitialized == 0) return false;

      memoizedIsInitialized = 1;
      return true;
    }

    public void writeTo(com.google.protobuf.CodedOutputStream output)
                        throws java.io.IOException {
      for (int i = 0; i < quasiIds_.size(); i++) {
        output.writeMessage(1, quasiIds_.get(i));
      }
      if (entityId_ != null) {
        output.writeMessage(2, getEntityId());
      }
      unknownFields.writeTo(output);
    }

    public int getSerializedSize() {
      int size = memoizedSize;
      if (size != -1) return size;

      size = 0;
      for (int i = 0; i < quasiIds_.size(); i++) {
        size += com.google.protobuf.CodedOutputStream
          .computeMessageSize(1, quasiIds_.get(i));
      }
      if (entityId_ != null) {
        size += com.google.protobuf.CodedOutputStream
          .computeMessageSize(2, getEntityId());
      }
      size += unknownFields.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.privacy.dlp.v2beta1.PrivacyMetric.KAnonymityConfig)) {
        return super.equals(obj);
      }
      com.google.privacy.dlp.v2beta1.PrivacyMetric.KAnonymityConfig other = (com.google.privacy.dlp.v2beta1.PrivacyMetric.KAnonymityConfig) obj;

      boolean result = true;
      result = result && getQuasiIdsList()
          .equals(other.getQuasiIdsList());
      result = result && (hasEntityId() == other.hasEntityId());
      if (hasEntityId()) {
        result = result && getEntityId()
            .equals(other.getEntityId());
      }
      result = result && unknownFields.equals(other.unknownFields);
      return result;
    }

    @java.lang.Override
    public int hashCode() {
      if (memoizedHashCode != 0) {
        return memoizedHashCode;
      }
      int hash = 41;
      hash = (19 * hash) + getDescriptor().hashCode();
      if (getQuasiIdsCount() > 0) {
        hash = (37 * hash) + QUASI_IDS_FIELD_NUMBER;
        hash = (53 * hash) + getQuasiIdsList().hashCode();
      }
      if (hasEntityId()) {
        hash = (37 * hash) + ENTITY_ID_FIELD_NUMBER;
        hash = (53 * hash) + getEntityId().hashCode();
      }
      hash = (29 * hash) + unknownFields.hashCode();
      memoizedHashCode = hash;
      return hash;
    }

    public static com.google.privacy.dlp.v2beta1.PrivacyMetric.KAnonymityConfig parseFrom(
        java.nio.ByteBuffer data)
        throws com.google.protobuf.InvalidProtocolBufferException {
      return PARSER.parseFrom(data);
    }
    public static com.google.privacy.dlp.v2beta1.PrivacyMetric.KAnonymityConfig parseFrom(
        java.nio.ByteBuffer data,
        com.google.protobuf.ExtensionRegistryLite extensionRegistry)
        throws com.google.protobuf.InvalidProtocolBufferException {
      return PARSER.parseFrom(data, extensionRegistry);
    }
    public static com.google.privacy.dlp.v2beta1.PrivacyMetric.KAnonymityConfig parseFrom(
        com.google.protobuf.ByteString data)
        throws com.google.protobuf.InvalidProtocolBufferException {
      return PARSER.parseFrom(data);
    }
    public static com.google.privacy.dlp.v2beta1.PrivacyMetric.KAnonymityConfig 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.privacy.dlp.v2beta1.PrivacyMetric.KAnonymityConfig parseFrom(byte[] data)
        throws com.google.protobuf.InvalidProtocolBufferException {
      return PARSER.parseFrom(data);
    }
    public static com.google.privacy.dlp.v2beta1.PrivacyMetric.KAnonymityConfig parseFrom(
        byte[] data,
        com.google.protobuf.ExtensionRegistryLite extensionRegistry)
        throws com.google.protobuf.InvalidProtocolBufferException {
      return PARSER.parseFrom(data, extensionRegistry);
    }
    public static com.google.privacy.dlp.v2beta1.PrivacyMetric.KAnonymityConfig parseFrom(java.io.InputStream input)
        throws java.io.IOException {
      return com.google.protobuf.GeneratedMessageV3
          .parseWithIOException(PARSER, input);
    }
    public static com.google.privacy.dlp.v2beta1.PrivacyMetric.KAnonymityConfig 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.privacy.dlp.v2beta1.PrivacyMetric.KAnonymityConfig parseDelimitedFrom(java.io.InputStream input)
        throws java.io.IOException {
      return com.google.protobuf.GeneratedMessageV3
          .parseDelimitedWithIOException(PARSER, input);
    }
    public static com.google.privacy.dlp.v2beta1.PrivacyMetric.KAnonymityConfig 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.privacy.dlp.v2beta1.PrivacyMetric.KAnonymityConfig parseFrom(
        com.google.protobuf.CodedInputStream input)
        throws java.io.IOException {
      return com.google.protobuf.GeneratedMessageV3
          .parseWithIOException(PARSER, input);
    }
    public static com.google.privacy.dlp.v2beta1.PrivacyMetric.KAnonymityConfig parseFrom(
        com.google.protobuf.CodedInputStream input,
        com.google.protobuf.ExtensionRegistryLite extensionRegistry)
        throws java.io.IOException {
      return com.google.protobuf.GeneratedMessageV3
          .parseWithIOException(PARSER, input, extensionRegistry);
    }

    public Builder newBuilderForType() { return newBuilder(); }
    public static Builder newBuilder() {
      return DEFAULT_INSTANCE.toBuilder();
    }
    public static Builder newBuilder(com.google.privacy.dlp.v2beta1.PrivacyMetric.KAnonymityConfig prototype) {
      return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype);
    }
    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>
     * k-anonymity metric, used for analysis of reidentification risk.
     * </pre>
     *
     * Protobuf type {@code google.privacy.dlp.v2beta1.PrivacyMetric.KAnonymityConfig}
     */
    public static final class Builder extends
        com.google.protobuf.GeneratedMessageV3.Builder<Builder> implements
        // @@protoc_insertion_point(builder_implements:google.privacy.dlp.v2beta1.PrivacyMetric.KAnonymityConfig)
        com.google.privacy.dlp.v2beta1.PrivacyMetric.KAnonymityConfigOrBuilder {
      public static final com.google.protobuf.Descriptors.Descriptor
          getDescriptor() {
        return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_PrivacyMetric_KAnonymityConfig_descriptor;
      }

      protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
          internalGetFieldAccessorTable() {
        return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_PrivacyMetric_KAnonymityConfig_fieldAccessorTable
            .ensureFieldAccessorsInitialized(
                com.google.privacy.dlp.v2beta1.PrivacyMetric.KAnonymityConfig.class, com.google.privacy.dlp.v2beta1.PrivacyMetric.KAnonymityConfig.Builder.class);
      }

      // Construct using com.google.privacy.dlp.v2beta1.PrivacyMetric.KAnonymityConfig.newBuilder()
      private Builder() {
        maybeForceBuilderInitialization();
      }

      private Builder(
          com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
        super(parent);
        maybeForceBuilderInitialization();
      }
      private void maybeForceBuilderInitialization() {
        if (com.google.protobuf.GeneratedMessageV3
                .alwaysUseFieldBuilders) {
          getQuasiIdsFieldBuilder();
        }
      }
      public Builder clear() {
        super.clear();
        if (quasiIdsBuilder_ == null) {
          quasiIds_ = java.util.Collections.emptyList();
          bitField0_ = (bitField0_ & ~0x00000001);
        } else {
          quasiIdsBuilder_.clear();
        }
        if (entityIdBuilder_ == null) {
          entityId_ = null;
        } else {
          entityId_ = null;
          entityIdBuilder_ = null;
        }
        return this;
      }

      public com.google.protobuf.Descriptors.Descriptor
          getDescriptorForType() {
        return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_PrivacyMetric_KAnonymityConfig_descriptor;
      }

      public com.google.privacy.dlp.v2beta1.PrivacyMetric.KAnonymityConfig getDefaultInstanceForType() {
        return com.google.privacy.dlp.v2beta1.PrivacyMetric.KAnonymityConfig.getDefaultInstance();
      }

      public com.google.privacy.dlp.v2beta1.PrivacyMetric.KAnonymityConfig build() {
        com.google.privacy.dlp.v2beta1.PrivacyMetric.KAnonymityConfig result = buildPartial();
        if (!result.isInitialized()) {
          throw newUninitializedMessageException(result);
        }
        return result;
      }

      public com.google.privacy.dlp.v2beta1.PrivacyMetric.KAnonymityConfig buildPartial() {
        com.google.privacy.dlp.v2beta1.PrivacyMetric.KAnonymityConfig result = new com.google.privacy.dlp.v2beta1.PrivacyMetric.KAnonymityConfig(this);
        int from_bitField0_ = bitField0_;
        int to_bitField0_ = 0;
        if (quasiIdsBuilder_ == null) {
          if (((bitField0_ & 0x00000001) == 0x00000001)) {
            quasiIds_ = java.util.Collections.unmodifiableList(quasiIds_);
            bitField0_ = (bitField0_ & ~0x00000001);
          }
          result.quasiIds_ = quasiIds_;
        } else {
          result.quasiIds_ = quasiIdsBuilder_.build();
        }
        if (entityIdBuilder_ == null) {
          result.entityId_ = entityId_;
        } else {
          result.entityId_ = entityIdBuilder_.build();
        }
        result.bitField0_ = to_bitField0_;
        onBuilt();
        return result;
      }

      public Builder clone() {
        return (Builder) super.clone();
      }
      public Builder setField(
          com.google.protobuf.Descriptors.FieldDescriptor field,
          java.lang.Object value) {
        return (Builder) super.setField(field, value);
      }
      public Builder clearField(
          com.google.protobuf.Descriptors.FieldDescriptor field) {
        return (Builder) super.clearField(field);
      }
      public Builder clearOneof(
          com.google.protobuf.Descriptors.OneofDescriptor oneof) {
        return (Builder) super.clearOneof(oneof);
      }
      public Builder setRepeatedField(
          com.google.protobuf.Descriptors.FieldDescriptor field,
          int index, java.lang.Object value) {
        return (Builder) super.setRepeatedField(field, index, value);
      }
      public Builder addRepeatedField(
          com.google.protobuf.Descriptors.FieldDescriptor field,
          java.lang.Object value) {
        return (Builder) super.addRepeatedField(field, value);
      }
      public Builder mergeFrom(com.google.protobuf.Message other) {
        if (other instanceof com.google.privacy.dlp.v2beta1.PrivacyMetric.KAnonymityConfig) {
          return mergeFrom((com.google.privacy.dlp.v2beta1.PrivacyMetric.KAnonymityConfig)other);
        } else {
          super.mergeFrom(other);
          return this;
        }
      }

      public Builder mergeFrom(com.google.privacy.dlp.v2beta1.PrivacyMetric.KAnonymityConfig other) {
        if (other == com.google.privacy.dlp.v2beta1.PrivacyMetric.KAnonymityConfig.getDefaultInstance()) return this;
        if (quasiIdsBuilder_ == null) {
          if (!other.quasiIds_.isEmpty()) {
            if (quasiIds_.isEmpty()) {
              quasiIds_ = other.quasiIds_;
              bitField0_ = (bitField0_ & ~0x00000001);
            } else {
              ensureQuasiIdsIsMutable();
              quasiIds_.addAll(other.quasiIds_);
            }
            onChanged();
          }
        } else {
          if (!other.quasiIds_.isEmpty()) {
            if (quasiIdsBuilder_.isEmpty()) {
              quasiIdsBuilder_.dispose();
              quasiIdsBuilder_ = null;
              quasiIds_ = other.quasiIds_;
              bitField0_ = (bitField0_ & ~0x00000001);
              quasiIdsBuilder_ = 
                com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders ?
                   getQuasiIdsFieldBuilder() : null;
            } else {
              quasiIdsBuilder_.addAllMessages(other.quasiIds_);
            }
          }
        }
        if (other.hasEntityId()) {
          mergeEntityId(other.getEntityId());
        }
        this.mergeUnknownFields(other.unknownFields);
        onChanged();
        return this;
      }

      public final boolean isInitialized() {
        return true;
      }

      public Builder mergeFrom(
          com.google.protobuf.CodedInputStream input,
          com.google.protobuf.ExtensionRegistryLite extensionRegistry)
          throws java.io.IOException {
        com.google.privacy.dlp.v2beta1.PrivacyMetric.KAnonymityConfig parsedMessage = null;
        try {
          parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry);
        } catch (com.google.protobuf.InvalidProtocolBufferException e) {
          parsedMessage = (com.google.privacy.dlp.v2beta1.PrivacyMetric.KAnonymityConfig) e.getUnfinishedMessage();
          throw e.unwrapIOException();
        } finally {
          if (parsedMessage != null) {
            mergeFrom(parsedMessage);
          }
        }
        return this;
      }
      private int bitField0_;

      private java.util.List<com.google.privacy.dlp.v2beta1.FieldId> quasiIds_ =
        java.util.Collections.emptyList();
      private void ensureQuasiIdsIsMutable() {
        if (!((bitField0_ & 0x00000001) == 0x00000001)) {
          quasiIds_ = new java.util.ArrayList<com.google.privacy.dlp.v2beta1.FieldId>(quasiIds_);
          bitField0_ |= 0x00000001;
         }
      }

      private com.google.protobuf.RepeatedFieldBuilderV3<
          com.google.privacy.dlp.v2beta1.FieldId, com.google.privacy.dlp.v2beta1.FieldId.Builder, com.google.privacy.dlp.v2beta1.FieldIdOrBuilder> quasiIdsBuilder_;

      /**
       * <pre>
       * Set of fields to compute k-anonymity over. When multiple fields are
       * specified, they are considered a single composite key. Structs and
       * repeated data types are not supported; however, nested fields are
       * supported so long as they are not structs themselves or nested within
       * a repeated field.
       * </pre>
       *
       * <code>repeated .google.privacy.dlp.v2beta1.FieldId quasi_ids = 1;</code>
       */
      public java.util.List<com.google.privacy.dlp.v2beta1.FieldId> getQuasiIdsList() {
        if (quasiIdsBuilder_ == null) {
          return java.util.Collections.unmodifiableList(quasiIds_);
        } else {
          return quasiIdsBuilder_.getMessageList();
        }
      }
      /**
       * <pre>
       * Set of fields to compute k-anonymity over. When multiple fields are
       * specified, they are considered a single composite key. Structs and
       * repeated data types are not supported; however, nested fields are
       * supported so long as they are not structs themselves or nested within
       * a repeated field.
       * </pre>
       *
       * <code>repeated .google.privacy.dlp.v2beta1.FieldId quasi_ids = 1;</code>
       */
      public int getQuasiIdsCount() {
        if (quasiIdsBuilder_ == null) {
          return quasiIds_.size();
        } else {
          return quasiIdsBuilder_.getCount();
        }
      }
      /**
       * <pre>
       * Set of fields to compute k-anonymity over. When multiple fields are
       * specified, they are considered a single composite key. Structs and
       * repeated data types are not supported; however, nested fields are
       * supported so long as they are not structs themselves or nested within
       * a repeated field.
       * </pre>
       *
       * <code>repeated .google.privacy.dlp.v2beta1.FieldId quasi_ids = 1;</code>
       */
      public com.google.privacy.dlp.v2beta1.FieldId getQuasiIds(int index) {
        if (quasiIdsBuilder_ == null) {
          return quasiIds_.get(index);
        } else {
          return quasiIdsBuilder_.getMessage(index);
        }
      }
      /**
       * <pre>
       * Set of fields to compute k-anonymity over. When multiple fields are
       * specified, they are considered a single composite key. Structs and
       * repeated data types are not supported; however, nested fields are
       * supported so long as they are not structs themselves or nested within
       * a repeated field.
       * </pre>
       *
       * <code>repeated .google.privacy.dlp.v2beta1.FieldId quasi_ids = 1;</code>
       */
      public Builder setQuasiIds(
          int index, com.google.privacy.dlp.v2beta1.FieldId value) {
        if (quasiIdsBuilder_ == null) {
          if (value == null) {
            throw new NullPointerException();
          }
          ensureQuasiIdsIsMutable();
          quasiIds_.set(index, value);
          onChanged();
        } else {
          quasiIdsBuilder_.setMessage(index, value);
        }
        return this;
      }
      /**
       * <pre>
       * Set of fields to compute k-anonymity over. When multiple fields are
       * specified, they are considered a single composite key. Structs and
       * repeated data types are not supported; however, nested fields are
       * supported so long as they are not structs themselves or nested within
       * a repeated field.
       * </pre>
       *
       * <code>repeated .google.privacy.dlp.v2beta1.FieldId quasi_ids = 1;</code>
       */
      public Builder setQuasiIds(
          int index, com.google.privacy.dlp.v2beta1.FieldId.Builder builderForValue) {
        if (quasiIdsBuilder_ == null) {
          ensureQuasiIdsIsMutable();
          quasiIds_.set(index, builderForValue.build());
          onChanged();
        } else {
          quasiIdsBuilder_.setMessage(index, builderForValue.build());
        }
        return this;
      }
      /**
       * <pre>
       * Set of fields to compute k-anonymity over. When multiple fields are
       * specified, they are considered a single composite key. Structs and
       * repeated data types are not supported; however, nested fields are
       * supported so long as they are not structs themselves or nested within
       * a repeated field.
       * </pre>
       *
       * <code>repeated .google.privacy.dlp.v2beta1.FieldId quasi_ids = 1;</code>
       */
      public Builder addQuasiIds(com.google.privacy.dlp.v2beta1.FieldId value) {
        if (quasiIdsBuilder_ == null) {
          if (value == null) {
            throw new NullPointerException();
          }
          ensureQuasiIdsIsMutable();
          quasiIds_.add(value);
          onChanged();
        } else {
          quasiIdsBuilder_.addMessage(value);
        }
        return this;
      }
      /**
       * <pre>
       * Set of fields to compute k-anonymity over. When multiple fields are
       * specified, they are considered a single composite key. Structs and
       * repeated data types are not supported; however, nested fields are
       * supported so long as they are not structs themselves or nested within
       * a repeated field.
       * </pre>
       *
       * <code>repeated .google.privacy.dlp.v2beta1.FieldId quasi_ids = 1;</code>
       */
      public Builder addQuasiIds(
          int index, com.google.privacy.dlp.v2beta1.FieldId value) {
        if (quasiIdsBuilder_ == null) {
          if (value == null) {
            throw new NullPointerException();
          }
          ensureQuasiIdsIsMutable();
          quasiIds_.add(index, value);
          onChanged();
        } else {
          quasiIdsBuilder_.addMessage(index, value);
        }
        return this;
      }
      /**
       * <pre>
       * Set of fields to compute k-anonymity over. When multiple fields are
       * specified, they are considered a single composite key. Structs and
       * repeated data types are not supported; however, nested fields are
       * supported so long as they are not structs themselves or nested within
       * a repeated field.
       * </pre>
       *
       * <code>repeated .google.privacy.dlp.v2beta1.FieldId quasi_ids = 1;</code>
       */
      public Builder addQuasiIds(
          com.google.privacy.dlp.v2beta1.FieldId.Builder builderForValue) {
        if (quasiIdsBuilder_ == null) {
          ensureQuasiIdsIsMutable();
          quasiIds_.add(builderForValue.build());
          onChanged();
        } else {
          quasiIdsBuilder_.addMessage(builderForValue.build());
        }
        return this;
      }
      /**
       * <pre>
       * Set of fields to compute k-anonymity over. When multiple fields are
       * specified, they are considered a single composite key. Structs and
       * repeated data types are not supported; however, nested fields are
       * supported so long as they are not structs themselves or nested within
       * a repeated field.
       * </pre>
       *
       * <code>repeated .google.privacy.dlp.v2beta1.FieldId quasi_ids = 1;</code>
       */
      public Builder addQuasiIds(
          int index, com.google.privacy.dlp.v2beta1.FieldId.Builder builderForValue) {
        if (quasiIdsBuilder_ == null) {
          ensureQuasiIdsIsMutable();
          quasiIds_.add(index, builderForValue.build());
          onChanged();
        } else {
          quasiIdsBuilder_.addMessage(index, builderForValue.build());
        }
        return this;
      }
      /**
       * <pre>
       * Set of fields to compute k-anonymity over. When multiple fields are
       * specified, they are considered a single composite key. Structs and
       * repeated data types are not supported; however, nested fields are
       * supported so long as they are not structs themselves or nested within
       * a repeated field.
       * </pre>
       *
       * <code>repeated .google.privacy.dlp.v2beta1.FieldId quasi_ids = 1;</code>
       */
      public Builder addAllQuasiIds(
          java.lang.Iterable<? extends com.google.privacy.dlp.v2beta1.FieldId> values) {
        if (quasiIdsBuilder_ == null) {
          ensureQuasiIdsIsMutable();
          com.google.protobuf.AbstractMessageLite.Builder.addAll(
              values, quasiIds_);
          onChanged();
        } else {
          quasiIdsBuilder_.addAllMessages(values);
        }
        return this;
      }
      /**
       * <pre>
       * Set of fields to compute k-anonymity over. When multiple fields are
       * specified, they are considered a single composite key. Structs and
       * repeated data types are not supported; however, nested fields are
       * supported so long as they are not structs themselves or nested within
       * a repeated field.
       * </pre>
       *
       * <code>repeated .google.privacy.dlp.v2beta1.FieldId quasi_ids = 1;</code>
       */
      public Builder clearQuasiIds() {
        if (quasiIdsBuilder_ == null) {
          quasiIds_ = java.util.Collections.emptyList();
          bitField0_ = (bitField0_ & ~0x00000001);
          onChanged();
        } else {
          quasiIdsBuilder_.clear();
        }
        return this;
      }
      /**
       * <pre>
       * Set of fields to compute k-anonymity over. When multiple fields are
       * specified, they are considered a single composite key. Structs and
       * repeated data types are not supported; however, nested fields are
       * supported so long as they are not structs themselves or nested within
       * a repeated field.
       * </pre>
       *
       * <code>repeated .google.privacy.dlp.v2beta1.FieldId quasi_ids = 1;</code>
       */
      public Builder removeQuasiIds(int index) {
        if (quasiIdsBuilder_ == null) {
          ensureQuasiIdsIsMutable();
          quasiIds_.remove(index);
          onChanged();
        } else {
          quasiIdsBuilder_.remove(index);
        }
        return this;
      }
      /**
       * <pre>
       * Set of fields to compute k-anonymity over. When multiple fields are
       * specified, they are considered a single composite key. Structs and
       * repeated data types are not supported; however, nested fields are
       * supported so long as they are not structs themselves or nested within
       * a repeated field.
       * </pre>
       *
       * <code>repeated .google.privacy.dlp.v2beta1.FieldId quasi_ids = 1;</code>
       */
      public com.google.privacy.dlp.v2beta1.FieldId.Builder getQuasiIdsBuilder(
          int index) {
        return getQuasiIdsFieldBuilder().getBuilder(index);
      }
      /**
       * <pre>
       * Set of fields to compute k-anonymity over. When multiple fields are
       * specified, they are considered a single composite key. Structs and
       * repeated data types are not supported; however, nested fields are
       * supported so long as they are not structs themselves or nested within
       * a repeated field.
       * </pre>
       *
       * <code>repeated .google.privacy.dlp.v2beta1.FieldId quasi_ids = 1;</code>
       */
      public com.google.privacy.dlp.v2beta1.FieldIdOrBuilder getQuasiIdsOrBuilder(
          int index) {
        if (quasiIdsBuilder_ == null) {
          return quasiIds_.get(index);  } else {
          return quasiIdsBuilder_.getMessageOrBuilder(index);
        }
      }
      /**
       * <pre>
       * Set of fields to compute k-anonymity over. When multiple fields are
       * specified, they are considered a single composite key. Structs and
       * repeated data types are not supported; however, nested fields are
       * supported so long as they are not structs themselves or nested within
       * a repeated field.
       * </pre>
       *
       * <code>repeated .google.privacy.dlp.v2beta1.FieldId quasi_ids = 1;</code>
       */
      public java.util.List<? extends com.google.privacy.dlp.v2beta1.FieldIdOrBuilder> 
           getQuasiIdsOrBuilderList() {
        if (quasiIdsBuilder_ != null) {
          return quasiIdsBuilder_.getMessageOrBuilderList();
        } else {
          return java.util.Collections.unmodifiableList(quasiIds_);
        }
      }
      /**
       * <pre>
       * Set of fields to compute k-anonymity over. When multiple fields are
       * specified, they are considered a single composite key. Structs and
       * repeated data types are not supported; however, nested fields are
       * supported so long as they are not structs themselves or nested within
       * a repeated field.
       * </pre>
       *
       * <code>repeated .google.privacy.dlp.v2beta1.FieldId quasi_ids = 1;</code>
       */
      public com.google.privacy.dlp.v2beta1.FieldId.Builder addQuasiIdsBuilder() {
        return getQuasiIdsFieldBuilder().addBuilder(
            com.google.privacy.dlp.v2beta1.FieldId.getDefaultInstance());
      }
      /**
       * <pre>
       * Set of fields to compute k-anonymity over. When multiple fields are
       * specified, they are considered a single composite key. Structs and
       * repeated data types are not supported; however, nested fields are
       * supported so long as they are not structs themselves or nested within
       * a repeated field.
       * </pre>
       *
       * <code>repeated .google.privacy.dlp.v2beta1.FieldId quasi_ids = 1;</code>
       */
      public com.google.privacy.dlp.v2beta1.FieldId.Builder addQuasiIdsBuilder(
          int index) {
        return getQuasiIdsFieldBuilder().addBuilder(
            index, com.google.privacy.dlp.v2beta1.FieldId.getDefaultInstance());
      }
      /**
       * <pre>
       * Set of fields to compute k-anonymity over. When multiple fields are
       * specified, they are considered a single composite key. Structs and
       * repeated data types are not supported; however, nested fields are
       * supported so long as they are not structs themselves or nested within
       * a repeated field.
       * </pre>
       *
       * <code>repeated .google.privacy.dlp.v2beta1.FieldId quasi_ids = 1;</code>
       */
      public java.util.List<com.google.privacy.dlp.v2beta1.FieldId.Builder> 
           getQuasiIdsBuilderList() {
        return getQuasiIdsFieldBuilder().getBuilderList();
      }
      private com.google.protobuf.RepeatedFieldBuilderV3<
          com.google.privacy.dlp.v2beta1.FieldId, com.google.privacy.dlp.v2beta1.FieldId.Builder, com.google.privacy.dlp.v2beta1.FieldIdOrBuilder> 
          getQuasiIdsFieldBuilder() {
        if (quasiIdsBuilder_ == null) {
          quasiIdsBuilder_ = new com.google.protobuf.RepeatedFieldBuilderV3<
              com.google.privacy.dlp.v2beta1.FieldId, com.google.privacy.dlp.v2beta1.FieldId.Builder, com.google.privacy.dlp.v2beta1.FieldIdOrBuilder>(
                  quasiIds_,
                  ((bitField0_ & 0x00000001) == 0x00000001),
                  getParentForChildren(),
                  isClean());
          quasiIds_ = null;
        }
        return quasiIdsBuilder_;
      }

      private com.google.privacy.dlp.v2beta1.EntityId entityId_ = null;
      private com.google.protobuf.SingleFieldBuilderV3<
          com.google.privacy.dlp.v2beta1.EntityId, com.google.privacy.dlp.v2beta1.EntityId.Builder, com.google.privacy.dlp.v2beta1.EntityIdOrBuilder> entityIdBuilder_;
      /**
       * <pre>
       * Optional message indicating that each distinct `EntityId` should not
       * contribute to the k-anonymity count more than once per equivalence class.
       * </pre>
       *
       * <code>.google.privacy.dlp.v2beta1.EntityId entity_id = 2;</code>
       */
      public boolean hasEntityId() {
        return entityIdBuilder_ != null || entityId_ != null;
      }
      /**
       * <pre>
       * Optional message indicating that each distinct `EntityId` should not
       * contribute to the k-anonymity count more than once per equivalence class.
       * </pre>
       *
       * <code>.google.privacy.dlp.v2beta1.EntityId entity_id = 2;</code>
       */
      public com.google.privacy.dlp.v2beta1.EntityId getEntityId() {
        if (entityIdBuilder_ == null) {
          return entityId_ == null ? com.google.privacy.dlp.v2beta1.EntityId.getDefaultInstance() : entityId_;
        } else {
          return entityIdBuilder_.getMessage();
        }
      }
      /**
       * <pre>
       * Optional message indicating that each distinct `EntityId` should not
       * contribute to the k-anonymity count more than once per equivalence class.
       * </pre>
       *
       * <code>.google.privacy.dlp.v2beta1.EntityId entity_id = 2;</code>
       */
      public Builder setEntityId(com.google.privacy.dlp.v2beta1.EntityId value) {
        if (entityIdBuilder_ == null) {
          if (value == null) {
            throw new NullPointerException();
          }
          entityId_ = value;
          onChanged();
        } else {
          entityIdBuilder_.setMessage(value);
        }

        return this;
      }
      /**
       * <pre>
       * Optional message indicating that each distinct `EntityId` should not
       * contribute to the k-anonymity count more than once per equivalence class.
       * </pre>
       *
       * <code>.google.privacy.dlp.v2beta1.EntityId entity_id = 2;</code>
       */
      public Builder setEntityId(
          com.google.privacy.dlp.v2beta1.EntityId.Builder builderForValue) {
        if (entityIdBuilder_ == null) {
          entityId_ = builderForValue.build();
          onChanged();
        } else {
          entityIdBuilder_.setMessage(builderForValue.build());
        }

        return this;
      }
      /**
       * <pre>
       * Optional message indicating that each distinct `EntityId` should not
       * contribute to the k-anonymity count more than once per equivalence class.
       * </pre>
       *
       * <code>.google.privacy.dlp.v2beta1.EntityId entity_id = 2;</code>
       */
      public Builder mergeEntityId(com.google.privacy.dlp.v2beta1.EntityId value) {
        if (entityIdBuilder_ == null) {
          if (entityId_ != null) {
            entityId_ =
              com.google.privacy.dlp.v2beta1.EntityId.newBuilder(entityId_).mergeFrom(value).buildPartial();
          } else {
            entityId_ = value;
          }
          onChanged();
        } else {
          entityIdBuilder_.mergeFrom(value);
        }

        return this;
      }
      /**
       * <pre>
       * Optional message indicating that each distinct `EntityId` should not
       * contribute to the k-anonymity count more than once per equivalence class.
       * </pre>
       *
       * <code>.google.privacy.dlp.v2beta1.EntityId entity_id = 2;</code>
       */
      public Builder clearEntityId() {
        if (entityIdBuilder_ == null) {
          entityId_ = null;
          onChanged();
        } else {
          entityId_ = null;
          entityIdBuilder_ = null;
        }

        return this;
      }
      /**
       * <pre>
       * Optional message indicating that each distinct `EntityId` should not
       * contribute to the k-anonymity count more than once per equivalence class.
       * </pre>
       *
       * <code>.google.privacy.dlp.v2beta1.EntityId entity_id = 2;</code>
       */
      public com.google.privacy.dlp.v2beta1.EntityId.Builder getEntityIdBuilder() {
        
        onChanged();
        return getEntityIdFieldBuilder().getBuilder();
      }
      /**
       * <pre>
       * Optional message indicating that each distinct `EntityId` should not
       * contribute to the k-anonymity count more than once per equivalence class.
       * </pre>
       *
       * <code>.google.privacy.dlp.v2beta1.EntityId entity_id = 2;</code>
       */
      public com.google.privacy.dlp.v2beta1.EntityIdOrBuilder getEntityIdOrBuilder() {
        if (entityIdBuilder_ != null) {
          return entityIdBuilder_.getMessageOrBuilder();
        } else {
          return entityId_ == null ?
              com.google.privacy.dlp.v2beta1.EntityId.getDefaultInstance() : entityId_;
        }
      }
      /**
       * <pre>
       * Optional message indicating that each distinct `EntityId` should not
       * contribute to the k-anonymity count more than once per equivalence class.
       * </pre>
       *
       * <code>.google.privacy.dlp.v2beta1.EntityId entity_id = 2;</code>
       */
      private com.google.protobuf.SingleFieldBuilderV3<
          com.google.privacy.dlp.v2beta1.EntityId, com.google.privacy.dlp.v2beta1.EntityId.Builder, com.google.privacy.dlp.v2beta1.EntityIdOrBuilder> 
          getEntityIdFieldBuilder() {
        if (entityIdBuilder_ == null) {
          entityIdBuilder_ = new com.google.protobuf.SingleFieldBuilderV3<
              com.google.privacy.dlp.v2beta1.EntityId, com.google.privacy.dlp.v2beta1.EntityId.Builder, com.google.privacy.dlp.v2beta1.EntityIdOrBuilder>(
                  getEntityId(),
                  getParentForChildren(),
                  isClean());
          entityId_ = null;
        }
        return entityIdBuilder_;
      }
      public final Builder setUnknownFields(
          final com.google.protobuf.UnknownFieldSet unknownFields) {
        return super.setUnknownFieldsProto3(unknownFields);
      }

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


      // @@protoc_insertion_point(builder_scope:google.privacy.dlp.v2beta1.PrivacyMetric.KAnonymityConfig)
    }

    // @@protoc_insertion_point(class_scope:google.privacy.dlp.v2beta1.PrivacyMetric.KAnonymityConfig)
    private static final com.google.privacy.dlp.v2beta1.PrivacyMetric.KAnonymityConfig DEFAULT_INSTANCE;
    static {
      DEFAULT_INSTANCE = new com.google.privacy.dlp.v2beta1.PrivacyMetric.KAnonymityConfig();
    }

    public static com.google.privacy.dlp.v2beta1.PrivacyMetric.KAnonymityConfig getDefaultInstance() {
      return DEFAULT_INSTANCE;
    }

    private static final com.google.protobuf.Parser<KAnonymityConfig>
        PARSER = new com.google.protobuf.AbstractParser<KAnonymityConfig>() {
      public KAnonymityConfig parsePartialFrom(
          com.google.protobuf.CodedInputStream input,
          com.google.protobuf.ExtensionRegistryLite extensionRegistry)
          throws com.google.protobuf.InvalidProtocolBufferException {
        return new KAnonymityConfig(input, extensionRegistry);
      }
    };

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

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

    public com.google.privacy.dlp.v2beta1.PrivacyMetric.KAnonymityConfig getDefaultInstanceForType() {
      return DEFAULT_INSTANCE;
    }

  }

  public interface LDiversityConfigOrBuilder extends
      // @@protoc_insertion_point(interface_extends:google.privacy.dlp.v2beta1.PrivacyMetric.LDiversityConfig)
      com.google.protobuf.MessageOrBuilder {

    /**
     * <pre>
     * Set of quasi-identifiers indicating how equivalence classes are
     * defined for the l-diversity computation. When multiple fields are
     * specified, they are considered a single composite key.
     * </pre>
     *
     * <code>repeated .google.privacy.dlp.v2beta1.FieldId quasi_ids = 1;</code>
     */
    java.util.List<com.google.privacy.dlp.v2beta1.FieldId> 
        getQuasiIdsList();
    /**
     * <pre>
     * Set of quasi-identifiers indicating how equivalence classes are
     * defined for the l-diversity computation. When multiple fields are
     * specified, they are considered a single composite key.
     * </pre>
     *
     * <code>repeated .google.privacy.dlp.v2beta1.FieldId quasi_ids = 1;</code>
     */
    com.google.privacy.dlp.v2beta1.FieldId getQuasiIds(int index);
    /**
     * <pre>
     * Set of quasi-identifiers indicating how equivalence classes are
     * defined for the l-diversity computation. When multiple fields are
     * specified, they are considered a single composite key.
     * </pre>
     *
     * <code>repeated .google.privacy.dlp.v2beta1.FieldId quasi_ids = 1;</code>
     */
    int getQuasiIdsCount();
    /**
     * <pre>
     * Set of quasi-identifiers indicating how equivalence classes are
     * defined for the l-diversity computation. When multiple fields are
     * specified, they are considered a single composite key.
     * </pre>
     *
     * <code>repeated .google.privacy.dlp.v2beta1.FieldId quasi_ids = 1;</code>
     */
    java.util.List<? extends com.google.privacy.dlp.v2beta1.FieldIdOrBuilder> 
        getQuasiIdsOrBuilderList();
    /**
     * <pre>
     * Set of quasi-identifiers indicating how equivalence classes are
     * defined for the l-diversity computation. When multiple fields are
     * specified, they are considered a single composite key.
     * </pre>
     *
     * <code>repeated .google.privacy.dlp.v2beta1.FieldId quasi_ids = 1;</code>
     */
    com.google.privacy.dlp.v2beta1.FieldIdOrBuilder getQuasiIdsOrBuilder(
        int index);

    /**
     * <pre>
     * Sensitive field for computing the l-value.
     * </pre>
     *
     * <code>.google.privacy.dlp.v2beta1.FieldId sensitive_attribute = 2;</code>
     */
    boolean hasSensitiveAttribute();
    /**
     * <pre>
     * Sensitive field for computing the l-value.
     * </pre>
     *
     * <code>.google.privacy.dlp.v2beta1.FieldId sensitive_attribute = 2;</code>
     */
    com.google.privacy.dlp.v2beta1.FieldId getSensitiveAttribute();
    /**
     * <pre>
     * Sensitive field for computing the l-value.
     * </pre>
     *
     * <code>.google.privacy.dlp.v2beta1.FieldId sensitive_attribute = 2;</code>
     */
    com.google.privacy.dlp.v2beta1.FieldIdOrBuilder getSensitiveAttributeOrBuilder();
  }
  /**
   * <pre>
   * l-diversity metric, used for analysis of reidentification risk.
   * </pre>
   *
   * Protobuf type {@code google.privacy.dlp.v2beta1.PrivacyMetric.LDiversityConfig}
   */
  public  static final class LDiversityConfig extends
      com.google.protobuf.GeneratedMessageV3 implements
      // @@protoc_insertion_point(message_implements:google.privacy.dlp.v2beta1.PrivacyMetric.LDiversityConfig)
      LDiversityConfigOrBuilder {
  private static final long serialVersionUID = 0L;
    // Use LDiversityConfig.newBuilder() to construct.
    private LDiversityConfig(com.google.protobuf.GeneratedMessageV3.Builder<?> builder) {
      super(builder);
    }
    private LDiversityConfig() {
      quasiIds_ = java.util.Collections.emptyList();
    }

    @java.lang.Override
    public final com.google.protobuf.UnknownFieldSet
    getUnknownFields() {
      return this.unknownFields;
    }
    private LDiversityConfig(
        com.google.protobuf.CodedInputStream input,
        com.google.protobuf.ExtensionRegistryLite extensionRegistry)
        throws com.google.protobuf.InvalidProtocolBufferException {
      this();
      if (extensionRegistry == null) {
        throw new java.lang.NullPointerException();
      }
      int mutable_bitField0_ = 0;
      com.google.protobuf.UnknownFieldSet.Builder unknownFields =
          com.google.protobuf.UnknownFieldSet.newBuilder();
      try {
        boolean done = false;
        while (!done) {
          int tag = input.readTag();
          switch (tag) {
            case 0:
              done = true;
              break;
            default: {
              if (!parseUnknownFieldProto3(
                  input, unknownFields, extensionRegistry, tag)) {
                done = true;
              }
              break;
            }
            case 10: {
              if (!((mutable_bitField0_ & 0x00000001) == 0x00000001)) {
                quasiIds_ = new java.util.ArrayList<com.google.privacy.dlp.v2beta1.FieldId>();
                mutable_bitField0_ |= 0x00000001;
              }
              quasiIds_.add(
                  input.readMessage(com.google.privacy.dlp.v2beta1.FieldId.parser(), extensionRegistry));
              break;
            }
            case 18: {
              com.google.privacy.dlp.v2beta1.FieldId.Builder subBuilder = null;
              if (sensitiveAttribute_ != null) {
                subBuilder = sensitiveAttribute_.toBuilder();
              }
              sensitiveAttribute_ = input.readMessage(com.google.privacy.dlp.v2beta1.FieldId.parser(), extensionRegistry);
              if (subBuilder != null) {
                subBuilder.mergeFrom(sensitiveAttribute_);
                sensitiveAttribute_ = subBuilder.buildPartial();
              }

              break;
            }
          }
        }
      } catch (com.google.protobuf.InvalidProtocolBufferException e) {
        throw e.setUnfinishedMessage(this);
      } catch (java.io.IOException e) {
        throw new com.google.protobuf.InvalidProtocolBufferException(
            e).setUnfinishedMessage(this);
      } finally {
        if (((mutable_bitField0_ & 0x00000001) == 0x00000001)) {
          quasiIds_ = java.util.Collections.unmodifiableList(quasiIds_);
        }
        this.unknownFields = unknownFields.build();
        makeExtensionsImmutable();
      }
    }
    public static final com.google.protobuf.Descriptors.Descriptor
        getDescriptor() {
      return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_PrivacyMetric_LDiversityConfig_descriptor;
    }

    protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
        internalGetFieldAccessorTable() {
      return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_PrivacyMetric_LDiversityConfig_fieldAccessorTable
          .ensureFieldAccessorsInitialized(
              com.google.privacy.dlp.v2beta1.PrivacyMetric.LDiversityConfig.class, com.google.privacy.dlp.v2beta1.PrivacyMetric.LDiversityConfig.Builder.class);
    }

    private int bitField0_;
    public static final int QUASI_IDS_FIELD_NUMBER = 1;
    private java.util.List<com.google.privacy.dlp.v2beta1.FieldId> quasiIds_;
    /**
     * <pre>
     * Set of quasi-identifiers indicating how equivalence classes are
     * defined for the l-diversity computation. When multiple fields are
     * specified, they are considered a single composite key.
     * </pre>
     *
     * <code>repeated .google.privacy.dlp.v2beta1.FieldId quasi_ids = 1;</code>
     */
    public java.util.List<com.google.privacy.dlp.v2beta1.FieldId> getQuasiIdsList() {
      return quasiIds_;
    }
    /**
     * <pre>
     * Set of quasi-identifiers indicating how equivalence classes are
     * defined for the l-diversity computation. When multiple fields are
     * specified, they are considered a single composite key.
     * </pre>
     *
     * <code>repeated .google.privacy.dlp.v2beta1.FieldId quasi_ids = 1;</code>
     */
    public java.util.List<? extends com.google.privacy.dlp.v2beta1.FieldIdOrBuilder> 
        getQuasiIdsOrBuilderList() {
      return quasiIds_;
    }
    /**
     * <pre>
     * Set of quasi-identifiers indicating how equivalence classes are
     * defined for the l-diversity computation. When multiple fields are
     * specified, they are considered a single composite key.
     * </pre>
     *
     * <code>repeated .google.privacy.dlp.v2beta1.FieldId quasi_ids = 1;</code>
     */
    public int getQuasiIdsCount() {
      return quasiIds_.size();
    }
    /**
     * <pre>
     * Set of quasi-identifiers indicating how equivalence classes are
     * defined for the l-diversity computation. When multiple fields are
     * specified, they are considered a single composite key.
     * </pre>
     *
     * <code>repeated .google.privacy.dlp.v2beta1.FieldId quasi_ids = 1;</code>
     */
    public com.google.privacy.dlp.v2beta1.FieldId getQuasiIds(int index) {
      return quasiIds_.get(index);
    }
    /**
     * <pre>
     * Set of quasi-identifiers indicating how equivalence classes are
     * defined for the l-diversity computation. When multiple fields are
     * specified, they are considered a single composite key.
     * </pre>
     *
     * <code>repeated .google.privacy.dlp.v2beta1.FieldId quasi_ids = 1;</code>
     */
    public com.google.privacy.dlp.v2beta1.FieldIdOrBuilder getQuasiIdsOrBuilder(
        int index) {
      return quasiIds_.get(index);
    }

    public static final int SENSITIVE_ATTRIBUTE_FIELD_NUMBER = 2;
    private com.google.privacy.dlp.v2beta1.FieldId sensitiveAttribute_;
    /**
     * <pre>
     * Sensitive field for computing the l-value.
     * </pre>
     *
     * <code>.google.privacy.dlp.v2beta1.FieldId sensitive_attribute = 2;</code>
     */
    public boolean hasSensitiveAttribute() {
      return sensitiveAttribute_ != null;
    }
    /**
     * <pre>
     * Sensitive field for computing the l-value.
     * </pre>
     *
     * <code>.google.privacy.dlp.v2beta1.FieldId sensitive_attribute = 2;</code>
     */
    public com.google.privacy.dlp.v2beta1.FieldId getSensitiveAttribute() {
      return sensitiveAttribute_ == null ? com.google.privacy.dlp.v2beta1.FieldId.getDefaultInstance() : sensitiveAttribute_;
    }
    /**
     * <pre>
     * Sensitive field for computing the l-value.
     * </pre>
     *
     * <code>.google.privacy.dlp.v2beta1.FieldId sensitive_attribute = 2;</code>
     */
    public com.google.privacy.dlp.v2beta1.FieldIdOrBuilder getSensitiveAttributeOrBuilder() {
      return getSensitiveAttribute();
    }

    private byte memoizedIsInitialized = -1;
    public final boolean isInitialized() {
      byte isInitialized = memoizedIsInitialized;
      if (isInitialized == 1) return true;
      if (isInitialized == 0) return false;

      memoizedIsInitialized = 1;
      return true;
    }

    public void writeTo(com.google.protobuf.CodedOutputStream output)
                        throws java.io.IOException {
      for (int i = 0; i < quasiIds_.size(); i++) {
        output.writeMessage(1, quasiIds_.get(i));
      }
      if (sensitiveAttribute_ != null) {
        output.writeMessage(2, getSensitiveAttribute());
      }
      unknownFields.writeTo(output);
    }

    public int getSerializedSize() {
      int size = memoizedSize;
      if (size != -1) return size;

      size = 0;
      for (int i = 0; i < quasiIds_.size(); i++) {
        size += com.google.protobuf.CodedOutputStream
          .computeMessageSize(1, quasiIds_.get(i));
      }
      if (sensitiveAttribute_ != null) {
        size += com.google.protobuf.CodedOutputStream
          .computeMessageSize(2, getSensitiveAttribute());
      }
      size += unknownFields.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.privacy.dlp.v2beta1.PrivacyMetric.LDiversityConfig)) {
        return super.equals(obj);
      }
      com.google.privacy.dlp.v2beta1.PrivacyMetric.LDiversityConfig other = (com.google.privacy.dlp.v2beta1.PrivacyMetric.LDiversityConfig) obj;

      boolean result = true;
      result = result && getQuasiIdsList()
          .equals(other.getQuasiIdsList());
      result = result && (hasSensitiveAttribute() == other.hasSensitiveAttribute());
      if (hasSensitiveAttribute()) {
        result = result && getSensitiveAttribute()
            .equals(other.getSensitiveAttribute());
      }
      result = result && unknownFields.equals(other.unknownFields);
      return result;
    }

    @java.lang.Override
    public int hashCode() {
      if (memoizedHashCode != 0) {
        return memoizedHashCode;
      }
      int hash = 41;
      hash = (19 * hash) + getDescriptor().hashCode();
      if (getQuasiIdsCount() > 0) {
        hash = (37 * hash) + QUASI_IDS_FIELD_NUMBER;
        hash = (53 * hash) + getQuasiIdsList().hashCode();
      }
      if (hasSensitiveAttribute()) {
        hash = (37 * hash) + SENSITIVE_ATTRIBUTE_FIELD_NUMBER;
        hash = (53 * hash) + getSensitiveAttribute().hashCode();
      }
      hash = (29 * hash) + unknownFields.hashCode();
      memoizedHashCode = hash;
      return hash;
    }

    public static com.google.privacy.dlp.v2beta1.PrivacyMetric.LDiversityConfig parseFrom(
        java.nio.ByteBuffer data)
        throws com.google.protobuf.InvalidProtocolBufferException {
      return PARSER.parseFrom(data);
    }
    public static com.google.privacy.dlp.v2beta1.PrivacyMetric.LDiversityConfig parseFrom(
        java.nio.ByteBuffer data,
        com.google.protobuf.ExtensionRegistryLite extensionRegistry)
        throws com.google.protobuf.InvalidProtocolBufferException {
      return PARSER.parseFrom(data, extensionRegistry);
    }
    public static com.google.privacy.dlp.v2beta1.PrivacyMetric.LDiversityConfig parseFrom(
        com.google.protobuf.ByteString data)
        throws com.google.protobuf.InvalidProtocolBufferException {
      return PARSER.parseFrom(data);
    }
    public static com.google.privacy.dlp.v2beta1.PrivacyMetric.LDiversityConfig 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.privacy.dlp.v2beta1.PrivacyMetric.LDiversityConfig parseFrom(byte[] data)
        throws com.google.protobuf.InvalidProtocolBufferException {
      return PARSER.parseFrom(data);
    }
    public static com.google.privacy.dlp.v2beta1.PrivacyMetric.LDiversityConfig parseFrom(
        byte[] data,
        com.google.protobuf.ExtensionRegistryLite extensionRegistry)
        throws com.google.protobuf.InvalidProtocolBufferException {
      return PARSER.parseFrom(data, extensionRegistry);
    }
    public static com.google.privacy.dlp.v2beta1.PrivacyMetric.LDiversityConfig parseFrom(java.io.InputStream input)
        throws java.io.IOException {
      return com.google.protobuf.GeneratedMessageV3
          .parseWithIOException(PARSER, input);
    }
    public static com.google.privacy.dlp.v2beta1.PrivacyMetric.LDiversityConfig 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.privacy.dlp.v2beta1.PrivacyMetric.LDiversityConfig parseDelimitedFrom(java.io.InputStream input)
        throws java.io.IOException {
      return com.google.protobuf.GeneratedMessageV3
          .parseDelimitedWithIOException(PARSER, input);
    }
    public static com.google.privacy.dlp.v2beta1.PrivacyMetric.LDiversityConfig 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.privacy.dlp.v2beta1.PrivacyMetric.LDiversityConfig parseFrom(
        com.google.protobuf.CodedInputStream input)
        throws java.io.IOException {
      return com.google.protobuf.GeneratedMessageV3
          .parseWithIOException(PARSER, input);
    }
    public static com.google.privacy.dlp.v2beta1.PrivacyMetric.LDiversityConfig parseFrom(
        com.google.protobuf.CodedInputStream input,
        com.google.protobuf.ExtensionRegistryLite extensionRegistry)
        throws java.io.IOException {
      return com.google.protobuf.GeneratedMessageV3
          .parseWithIOException(PARSER, input, extensionRegistry);
    }

    public Builder newBuilderForType() { return newBuilder(); }
    public static Builder newBuilder() {
      return DEFAULT_INSTANCE.toBuilder();
    }
    public static Builder newBuilder(com.google.privacy.dlp.v2beta1.PrivacyMetric.LDiversityConfig prototype) {
      return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype);
    }
    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>
     * l-diversity metric, used for analysis of reidentification risk.
     * </pre>
     *
     * Protobuf type {@code google.privacy.dlp.v2beta1.PrivacyMetric.LDiversityConfig}
     */
    public static final class Builder extends
        com.google.protobuf.GeneratedMessageV3.Builder<Builder> implements
        // @@protoc_insertion_point(builder_implements:google.privacy.dlp.v2beta1.PrivacyMetric.LDiversityConfig)
        com.google.privacy.dlp.v2beta1.PrivacyMetric.LDiversityConfigOrBuilder {
      public static final com.google.protobuf.Descriptors.Descriptor
          getDescriptor() {
        return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_PrivacyMetric_LDiversityConfig_descriptor;
      }

      protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
          internalGetFieldAccessorTable() {
        return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_PrivacyMetric_LDiversityConfig_fieldAccessorTable
            .ensureFieldAccessorsInitialized(
                com.google.privacy.dlp.v2beta1.PrivacyMetric.LDiversityConfig.class, com.google.privacy.dlp.v2beta1.PrivacyMetric.LDiversityConfig.Builder.class);
      }

      // Construct using com.google.privacy.dlp.v2beta1.PrivacyMetric.LDiversityConfig.newBuilder()
      private Builder() {
        maybeForceBuilderInitialization();
      }

      private Builder(
          com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
        super(parent);
        maybeForceBuilderInitialization();
      }
      private void maybeForceBuilderInitialization() {
        if (com.google.protobuf.GeneratedMessageV3
                .alwaysUseFieldBuilders) {
          getQuasiIdsFieldBuilder();
        }
      }
      public Builder clear() {
        super.clear();
        if (quasiIdsBuilder_ == null) {
          quasiIds_ = java.util.Collections.emptyList();
          bitField0_ = (bitField0_ & ~0x00000001);
        } else {
          quasiIdsBuilder_.clear();
        }
        if (sensitiveAttributeBuilder_ == null) {
          sensitiveAttribute_ = null;
        } else {
          sensitiveAttribute_ = null;
          sensitiveAttributeBuilder_ = null;
        }
        return this;
      }

      public com.google.protobuf.Descriptors.Descriptor
          getDescriptorForType() {
        return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_PrivacyMetric_LDiversityConfig_descriptor;
      }

      public com.google.privacy.dlp.v2beta1.PrivacyMetric.LDiversityConfig getDefaultInstanceForType() {
        return com.google.privacy.dlp.v2beta1.PrivacyMetric.LDiversityConfig.getDefaultInstance();
      }

      public com.google.privacy.dlp.v2beta1.PrivacyMetric.LDiversityConfig build() {
        com.google.privacy.dlp.v2beta1.PrivacyMetric.LDiversityConfig result = buildPartial();
        if (!result.isInitialized()) {
          throw newUninitializedMessageException(result);
        }
        return result;
      }

      public com.google.privacy.dlp.v2beta1.PrivacyMetric.LDiversityConfig buildPartial() {
        com.google.privacy.dlp.v2beta1.PrivacyMetric.LDiversityConfig result = new com.google.privacy.dlp.v2beta1.PrivacyMetric.LDiversityConfig(this);
        int from_bitField0_ = bitField0_;
        int to_bitField0_ = 0;
        if (quasiIdsBuilder_ == null) {
          if (((bitField0_ & 0x00000001) == 0x00000001)) {
            quasiIds_ = java.util.Collections.unmodifiableList(quasiIds_);
            bitField0_ = (bitField0_ & ~0x00000001);
          }
          result.quasiIds_ = quasiIds_;
        } else {
          result.quasiIds_ = quasiIdsBuilder_.build();
        }
        if (sensitiveAttributeBuilder_ == null) {
          result.sensitiveAttribute_ = sensitiveAttribute_;
        } else {
          result.sensitiveAttribute_ = sensitiveAttributeBuilder_.build();
        }
        result.bitField0_ = to_bitField0_;
        onBuilt();
        return result;
      }

      public Builder clone() {
        return (Builder) super.clone();
      }
      public Builder setField(
          com.google.protobuf.Descriptors.FieldDescriptor field,
          java.lang.Object value) {
        return (Builder) super.setField(field, value);
      }
      public Builder clearField(
          com.google.protobuf.Descriptors.FieldDescriptor field) {
        return (Builder) super.clearField(field);
      }
      public Builder clearOneof(
          com.google.protobuf.Descriptors.OneofDescriptor oneof) {
        return (Builder) super.clearOneof(oneof);
      }
      public Builder setRepeatedField(
          com.google.protobuf.Descriptors.FieldDescriptor field,
          int index, java.lang.Object value) {
        return (Builder) super.setRepeatedField(field, index, value);
      }
      public Builder addRepeatedField(
          com.google.protobuf.Descriptors.FieldDescriptor field,
          java.lang.Object value) {
        return (Builder) super.addRepeatedField(field, value);
      }
      public Builder mergeFrom(com.google.protobuf.Message other) {
        if (other instanceof com.google.privacy.dlp.v2beta1.PrivacyMetric.LDiversityConfig) {
          return mergeFrom((com.google.privacy.dlp.v2beta1.PrivacyMetric.LDiversityConfig)other);
        } else {
          super.mergeFrom(other);
          return this;
        }
      }

      public Builder mergeFrom(com.google.privacy.dlp.v2beta1.PrivacyMetric.LDiversityConfig other) {
        if (other == com.google.privacy.dlp.v2beta1.PrivacyMetric.LDiversityConfig.getDefaultInstance()) return this;
        if (quasiIdsBuilder_ == null) {
          if (!other.quasiIds_.isEmpty()) {
            if (quasiIds_.isEmpty()) {
              quasiIds_ = other.quasiIds_;
              bitField0_ = (bitField0_ & ~0x00000001);
            } else {
              ensureQuasiIdsIsMutable();
              quasiIds_.addAll(other.quasiIds_);
            }
            onChanged();
          }
        } else {
          if (!other.quasiIds_.isEmpty()) {
            if (quasiIdsBuilder_.isEmpty()) {
              quasiIdsBuilder_.dispose();
              quasiIdsBuilder_ = null;
              quasiIds_ = other.quasiIds_;
              bitField0_ = (bitField0_ & ~0x00000001);
              quasiIdsBuilder_ = 
                com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders ?
                   getQuasiIdsFieldBuilder() : null;
            } else {
              quasiIdsBuilder_.addAllMessages(other.quasiIds_);
            }
          }
        }
        if (other.hasSensitiveAttribute()) {
          mergeSensitiveAttribute(other.getSensitiveAttribute());
        }
        this.mergeUnknownFields(other.unknownFields);
        onChanged();
        return this;
      }

      public final boolean isInitialized() {
        return true;
      }

      public Builder mergeFrom(
          com.google.protobuf.CodedInputStream input,
          com.google.protobuf.ExtensionRegistryLite extensionRegistry)
          throws java.io.IOException {
        com.google.privacy.dlp.v2beta1.PrivacyMetric.LDiversityConfig parsedMessage = null;
        try {
          parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry);
        } catch (com.google.protobuf.InvalidProtocolBufferException e) {
          parsedMessage = (com.google.privacy.dlp.v2beta1.PrivacyMetric.LDiversityConfig) e.getUnfinishedMessage();
          throw e.unwrapIOException();
        } finally {
          if (parsedMessage != null) {
            mergeFrom(parsedMessage);
          }
        }
        return this;
      }
      private int bitField0_;

      private java.util.List<com.google.privacy.dlp.v2beta1.FieldId> quasiIds_ =
        java.util.Collections.emptyList();
      private void ensureQuasiIdsIsMutable() {
        if (!((bitField0_ & 0x00000001) == 0x00000001)) {
          quasiIds_ = new java.util.ArrayList<com.google.privacy.dlp.v2beta1.FieldId>(quasiIds_);
          bitField0_ |= 0x00000001;
         }
      }

      private com.google.protobuf.RepeatedFieldBuilderV3<
          com.google.privacy.dlp.v2beta1.FieldId, com.google.privacy.dlp.v2beta1.FieldId.Builder, com.google.privacy.dlp.v2beta1.FieldIdOrBuilder> quasiIdsBuilder_;

      /**
       * <pre>
       * Set of quasi-identifiers indicating how equivalence classes are
       * defined for the l-diversity computation. When multiple fields are
       * specified, they are considered a single composite key.
       * </pre>
       *
       * <code>repeated .google.privacy.dlp.v2beta1.FieldId quasi_ids = 1;</code>
       */
      public java.util.List<com.google.privacy.dlp.v2beta1.FieldId> getQuasiIdsList() {
        if (quasiIdsBuilder_ == null) {
          return java.util.Collections.unmodifiableList(quasiIds_);
        } else {
          return quasiIdsBuilder_.getMessageList();
        }
      }
      /**
       * <pre>
       * Set of quasi-identifiers indicating how equivalence classes are
       * defined for the l-diversity computation. When multiple fields are
       * specified, they are considered a single composite key.
       * </pre>
       *
       * <code>repeated .google.privacy.dlp.v2beta1.FieldId quasi_ids = 1;</code>
       */
      public int getQuasiIdsCount() {
        if (quasiIdsBuilder_ == null) {
          return quasiIds_.size();
        } else {
          return quasiIdsBuilder_.getCount();
        }
      }
      /**
       * <pre>
       * Set of quasi-identifiers indicating how equivalence classes are
       * defined for the l-diversity computation. When multiple fields are
       * specified, they are considered a single composite key.
       * </pre>
       *
       * <code>repeated .google.privacy.dlp.v2beta1.FieldId quasi_ids = 1;</code>
       */
      public com.google.privacy.dlp.v2beta1.FieldId getQuasiIds(int index) {
        if (quasiIdsBuilder_ == null) {
          return quasiIds_.get(index);
        } else {
          return quasiIdsBuilder_.getMessage(index);
        }
      }
      /**
       * <pre>
       * Set of quasi-identifiers indicating how equivalence classes are
       * defined for the l-diversity computation. When multiple fields are
       * specified, they are considered a single composite key.
       * </pre>
       *
       * <code>repeated .google.privacy.dlp.v2beta1.FieldId quasi_ids = 1;</code>
       */
      public Builder setQuasiIds(
          int index, com.google.privacy.dlp.v2beta1.FieldId value) {
        if (quasiIdsBuilder_ == null) {
          if (value == null) {
            throw new NullPointerException();
          }
          ensureQuasiIdsIsMutable();
          quasiIds_.set(index, value);
          onChanged();
        } else {
          quasiIdsBuilder_.setMessage(index, value);
        }
        return this;
      }
      /**
       * <pre>
       * Set of quasi-identifiers indicating how equivalence classes are
       * defined for the l-diversity computation. When multiple fields are
       * specified, they are considered a single composite key.
       * </pre>
       *
       * <code>repeated .google.privacy.dlp.v2beta1.FieldId quasi_ids = 1;</code>
       */
      public Builder setQuasiIds(
          int index, com.google.privacy.dlp.v2beta1.FieldId.Builder builderForValue) {
        if (quasiIdsBuilder_ == null) {
          ensureQuasiIdsIsMutable();
          quasiIds_.set(index, builderForValue.build());
          onChanged();
        } else {
          quasiIdsBuilder_.setMessage(index, builderForValue.build());
        }
        return this;
      }
      /**
       * <pre>
       * Set of quasi-identifiers indicating how equivalence classes are
       * defined for the l-diversity computation. When multiple fields are
       * specified, they are considered a single composite key.
       * </pre>
       *
       * <code>repeated .google.privacy.dlp.v2beta1.FieldId quasi_ids = 1;</code>
       */
      public Builder addQuasiIds(com.google.privacy.dlp.v2beta1.FieldId value) {
        if (quasiIdsBuilder_ == null) {
          if (value == null) {
            throw new NullPointerException();
          }
          ensureQuasiIdsIsMutable();
          quasiIds_.add(value);
          onChanged();
        } else {
          quasiIdsBuilder_.addMessage(value);
        }
        return this;
      }
      /**
       * <pre>
       * Set of quasi-identifiers indicating how equivalence classes are
       * defined for the l-diversity computation. When multiple fields are
       * specified, they are considered a single composite key.
       * </pre>
       *
       * <code>repeated .google.privacy.dlp.v2beta1.FieldId quasi_ids = 1;</code>
       */
      public Builder addQuasiIds(
          int index, com.google.privacy.dlp.v2beta1.FieldId value) {
        if (quasiIdsBuilder_ == null) {
          if (value == null) {
            throw new NullPointerException();
          }
          ensureQuasiIdsIsMutable();
          quasiIds_.add(index, value);
          onChanged();
        } else {
          quasiIdsBuilder_.addMessage(index, value);
        }
        return this;
      }
      /**
       * <pre>
       * Set of quasi-identifiers indicating how equivalence classes are
       * defined for the l-diversity computation. When multiple fields are
       * specified, they are considered a single composite key.
       * </pre>
       *
       * <code>repeated .google.privacy.dlp.v2beta1.FieldId quasi_ids = 1;</code>
       */
      public Builder addQuasiIds(
          com.google.privacy.dlp.v2beta1.FieldId.Builder builderForValue) {
        if (quasiIdsBuilder_ == null) {
          ensureQuasiIdsIsMutable();
          quasiIds_.add(builderForValue.build());
          onChanged();
        } else {
          quasiIdsBuilder_.addMessage(builderForValue.build());
        }
        return this;
      }
      /**
       * <pre>
       * Set of quasi-identifiers indicating how equivalence classes are
       * defined for the l-diversity computation. When multiple fields are
       * specified, they are considered a single composite key.
       * </pre>
       *
       * <code>repeated .google.privacy.dlp.v2beta1.FieldId quasi_ids = 1;</code>
       */
      public Builder addQuasiIds(
          int index, com.google.privacy.dlp.v2beta1.FieldId.Builder builderForValue) {
        if (quasiIdsBuilder_ == null) {
          ensureQuasiIdsIsMutable();
          quasiIds_.add(index, builderForValue.build());
          onChanged();
        } else {
          quasiIdsBuilder_.addMessage(index, builderForValue.build());
        }
        return this;
      }
      /**
       * <pre>
       * Set of quasi-identifiers indicating how equivalence classes are
       * defined for the l-diversity computation. When multiple fields are
       * specified, they are considered a single composite key.
       * </pre>
       *
       * <code>repeated .google.privacy.dlp.v2beta1.FieldId quasi_ids = 1;</code>
       */
      public Builder addAllQuasiIds(
          java.lang.Iterable<? extends com.google.privacy.dlp.v2beta1.FieldId> values) {
        if (quasiIdsBuilder_ == null) {
          ensureQuasiIdsIsMutable();
          com.google.protobuf.AbstractMessageLite.Builder.addAll(
              values, quasiIds_);
          onChanged();
        } else {
          quasiIdsBuilder_.addAllMessages(values);
        }
        return this;
      }
      /**
       * <pre>
       * Set of quasi-identifiers indicating how equivalence classes are
       * defined for the l-diversity computation. When multiple fields are
       * specified, they are considered a single composite key.
       * </pre>
       *
       * <code>repeated .google.privacy.dlp.v2beta1.FieldId quasi_ids = 1;</code>
       */
      public Builder clearQuasiIds() {
        if (quasiIdsBuilder_ == null) {
          quasiIds_ = java.util.Collections.emptyList();
          bitField0_ = (bitField0_ & ~0x00000001);
          onChanged();
        } else {
          quasiIdsBuilder_.clear();
        }
        return this;
      }
      /**
       * <pre>
       * Set of quasi-identifiers indicating how equivalence classes are
       * defined for the l-diversity computation. When multiple fields are
       * specified, they are considered a single composite key.
       * </pre>
       *
       * <code>repeated .google.privacy.dlp.v2beta1.FieldId quasi_ids = 1;</code>
       */
      public Builder removeQuasiIds(int index) {
        if (quasiIdsBuilder_ == null) {
          ensureQuasiIdsIsMutable();
          quasiIds_.remove(index);
          onChanged();
        } else {
          quasiIdsBuilder_.remove(index);
        }
        return this;
      }
      /**
       * <pre>
       * Set of quasi-identifiers indicating how equivalence classes are
       * defined for the l-diversity computation. When multiple fields are
       * specified, they are considered a single composite key.
       * </pre>
       *
       * <code>repeated .google.privacy.dlp.v2beta1.FieldId quasi_ids = 1;</code>
       */
      public com.google.privacy.dlp.v2beta1.FieldId.Builder getQuasiIdsBuilder(
          int index) {
        return getQuasiIdsFieldBuilder().getBuilder(index);
      }
      /**
       * <pre>
       * Set of quasi-identifiers indicating how equivalence classes are
       * defined for the l-diversity computation. When multiple fields are
       * specified, they are considered a single composite key.
       * </pre>
       *
       * <code>repeated .google.privacy.dlp.v2beta1.FieldId quasi_ids = 1;</code>
       */
      public com.google.privacy.dlp.v2beta1.FieldIdOrBuilder getQuasiIdsOrBuilder(
          int index) {
        if (quasiIdsBuilder_ == null) {
          return quasiIds_.get(index);  } else {
          return quasiIdsBuilder_.getMessageOrBuilder(index);
        }
      }
      /**
       * <pre>
       * Set of quasi-identifiers indicating how equivalence classes are
       * defined for the l-diversity computation. When multiple fields are
       * specified, they are considered a single composite key.
       * </pre>
       *
       * <code>repeated .google.privacy.dlp.v2beta1.FieldId quasi_ids = 1;</code>
       */
      public java.util.List<? extends com.google.privacy.dlp.v2beta1.FieldIdOrBuilder> 
           getQuasiIdsOrBuilderList() {
        if (quasiIdsBuilder_ != null) {
          return quasiIdsBuilder_.getMessageOrBuilderList();
        } else {
          return java.util.Collections.unmodifiableList(quasiIds_);
        }
      }
      /**
       * <pre>
       * Set of quasi-identifiers indicating how equivalence classes are
       * defined for the l-diversity computation. When multiple fields are
       * specified, they are considered a single composite key.
       * </pre>
       *
       * <code>repeated .google.privacy.dlp.v2beta1.FieldId quasi_ids = 1;</code>
       */
      public com.google.privacy.dlp.v2beta1.FieldId.Builder addQuasiIdsBuilder() {
        return getQuasiIdsFieldBuilder().addBuilder(
            com.google.privacy.dlp.v2beta1.FieldId.getDefaultInstance());
      }
      /**
       * <pre>
       * Set of quasi-identifiers indicating how equivalence classes are
       * defined for the l-diversity computation. When multiple fields are
       * specified, they are considered a single composite key.
       * </pre>
       *
       * <code>repeated .google.privacy.dlp.v2beta1.FieldId quasi_ids = 1;</code>
       */
      public com.google.privacy.dlp.v2beta1.FieldId.Builder addQuasiIdsBuilder(
          int index) {
        return getQuasiIdsFieldBuilder().addBuilder(
            index, com.google.privacy.dlp.v2beta1.FieldId.getDefaultInstance());
      }
      /**
       * <pre>
       * Set of quasi-identifiers indicating how equivalence classes are
       * defined for the l-diversity computation. When multiple fields are
       * specified, they are considered a single composite key.
       * </pre>
       *
       * <code>repeated .google.privacy.dlp.v2beta1.FieldId quasi_ids = 1;</code>
       */
      public java.util.List<com.google.privacy.dlp.v2beta1.FieldId.Builder> 
           getQuasiIdsBuilderList() {
        return getQuasiIdsFieldBuilder().getBuilderList();
      }
      private com.google.protobuf.RepeatedFieldBuilderV3<
          com.google.privacy.dlp.v2beta1.FieldId, com.google.privacy.dlp.v2beta1.FieldId.Builder, com.google.privacy.dlp.v2beta1.FieldIdOrBuilder> 
          getQuasiIdsFieldBuilder() {
        if (quasiIdsBuilder_ == null) {
          quasiIdsBuilder_ = new com.google.protobuf.RepeatedFieldBuilderV3<
              com.google.privacy.dlp.v2beta1.FieldId, com.google.privacy.dlp.v2beta1.FieldId.Builder, com.google.privacy.dlp.v2beta1.FieldIdOrBuilder>(
                  quasiIds_,
                  ((bitField0_ & 0x00000001) == 0x00000001),
                  getParentForChildren(),
                  isClean());
          quasiIds_ = null;
        }
        return quasiIdsBuilder_;
      }

      private com.google.privacy.dlp.v2beta1.FieldId sensitiveAttribute_ = null;
      private com.google.protobuf.SingleFieldBuilderV3<
          com.google.privacy.dlp.v2beta1.FieldId, com.google.privacy.dlp.v2beta1.FieldId.Builder, com.google.privacy.dlp.v2beta1.FieldIdOrBuilder> sensitiveAttributeBuilder_;
      /**
       * <pre>
       * Sensitive field for computing the l-value.
       * </pre>
       *
       * <code>.google.privacy.dlp.v2beta1.FieldId sensitive_attribute = 2;</code>
       */
      public boolean hasSensitiveAttribute() {
        return sensitiveAttributeBuilder_ != null || sensitiveAttribute_ != null;
      }
      /**
       * <pre>
       * Sensitive field for computing the l-value.
       * </pre>
       *
       * <code>.google.privacy.dlp.v2beta1.FieldId sensitive_attribute = 2;</code>
       */
      public com.google.privacy.dlp.v2beta1.FieldId getSensitiveAttribute() {
        if (sensitiveAttributeBuilder_ == null) {
          return sensitiveAttribute_ == null ? com.google.privacy.dlp.v2beta1.FieldId.getDefaultInstance() : sensitiveAttribute_;
        } else {
          return sensitiveAttributeBuilder_.getMessage();
        }
      }
      /**
       * <pre>
       * Sensitive field for computing the l-value.
       * </pre>
       *
       * <code>.google.privacy.dlp.v2beta1.FieldId sensitive_attribute = 2;</code>
       */
      public Builder setSensitiveAttribute(com.google.privacy.dlp.v2beta1.FieldId value) {
        if (sensitiveAttributeBuilder_ == null) {
          if (value == null) {
            throw new NullPointerException();
          }
          sensitiveAttribute_ = value;
          onChanged();
        } else {
          sensitiveAttributeBuilder_.setMessage(value);
        }

        return this;
      }
      /**
       * <pre>
       * Sensitive field for computing the l-value.
       * </pre>
       *
       * <code>.google.privacy.dlp.v2beta1.FieldId sensitive_attribute = 2;</code>
       */
      public Builder setSensitiveAttribute(
          com.google.privacy.dlp.v2beta1.FieldId.Builder builderForValue) {
        if (sensitiveAttributeBuilder_ == null) {
          sensitiveAttribute_ = builderForValue.build();
          onChanged();
        } else {
          sensitiveAttributeBuilder_.setMessage(builderForValue.build());
        }

        return this;
      }
      /**
       * <pre>
       * Sensitive field for computing the l-value.
       * </pre>
       *
       * <code>.google.privacy.dlp.v2beta1.FieldId sensitive_attribute = 2;</code>
       */
      public Builder mergeSensitiveAttribute(com.google.privacy.dlp.v2beta1.FieldId value) {
        if (sensitiveAttributeBuilder_ == null) {
          if (sensitiveAttribute_ != null) {
            sensitiveAttribute_ =
              com.google.privacy.dlp.v2beta1.FieldId.newBuilder(sensitiveAttribute_).mergeFrom(value).buildPartial();
          } else {
            sensitiveAttribute_ = value;
          }
          onChanged();
        } else {
          sensitiveAttributeBuilder_.mergeFrom(value);
        }

        return this;
      }
      /**
       * <pre>
       * Sensitive field for computing the l-value.
       * </pre>
       *
       * <code>.google.privacy.dlp.v2beta1.FieldId sensitive_attribute = 2;</code>
       */
      public Builder clearSensitiveAttribute() {
        if (sensitiveAttributeBuilder_ == null) {
          sensitiveAttribute_ = null;
          onChanged();
        } else {
          sensitiveAttribute_ = null;
          sensitiveAttributeBuilder_ = null;
        }

        return this;
      }
      /**
       * <pre>
       * Sensitive field for computing the l-value.
       * </pre>
       *
       * <code>.google.privacy.dlp.v2beta1.FieldId sensitive_attribute = 2;</code>
       */
      public com.google.privacy.dlp.v2beta1.FieldId.Builder getSensitiveAttributeBuilder() {
        
        onChanged();
        return getSensitiveAttributeFieldBuilder().getBuilder();
      }
      /**
       * <pre>
       * Sensitive field for computing the l-value.
       * </pre>
       *
       * <code>.google.privacy.dlp.v2beta1.FieldId sensitive_attribute = 2;</code>
       */
      public com.google.privacy.dlp.v2beta1.FieldIdOrBuilder getSensitiveAttributeOrBuilder() {
        if (sensitiveAttributeBuilder_ != null) {
          return sensitiveAttributeBuilder_.getMessageOrBuilder();
        } else {
          return sensitiveAttribute_ == null ?
              com.google.privacy.dlp.v2beta1.FieldId.getDefaultInstance() : sensitiveAttribute_;
        }
      }
      /**
       * <pre>
       * Sensitive field for computing the l-value.
       * </pre>
       *
       * <code>.google.privacy.dlp.v2beta1.FieldId sensitive_attribute = 2;</code>
       */
      private com.google.protobuf.SingleFieldBuilderV3<
          com.google.privacy.dlp.v2beta1.FieldId, com.google.privacy.dlp.v2beta1.FieldId.Builder, com.google.privacy.dlp.v2beta1.FieldIdOrBuilder> 
          getSensitiveAttributeFieldBuilder() {
        if (sensitiveAttributeBuilder_ == null) {
          sensitiveAttributeBuilder_ = new com.google.protobuf.SingleFieldBuilderV3<
              com.google.privacy.dlp.v2beta1.FieldId, com.google.privacy.dlp.v2beta1.FieldId.Builder, com.google.privacy.dlp.v2beta1.FieldIdOrBuilder>(
                  getSensitiveAttribute(),
                  getParentForChildren(),
                  isClean());
          sensitiveAttribute_ = null;
        }
        return sensitiveAttributeBuilder_;
      }
      public final Builder setUnknownFields(
          final com.google.protobuf.UnknownFieldSet unknownFields) {
        return super.setUnknownFieldsProto3(unknownFields);
      }

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


      // @@protoc_insertion_point(builder_scope:google.privacy.dlp.v2beta1.PrivacyMetric.LDiversityConfig)
    }

    // @@protoc_insertion_point(class_scope:google.privacy.dlp.v2beta1.PrivacyMetric.LDiversityConfig)
    private static final com.google.privacy.dlp.v2beta1.PrivacyMetric.LDiversityConfig DEFAULT_INSTANCE;
    static {
      DEFAULT_INSTANCE = new com.google.privacy.dlp.v2beta1.PrivacyMetric.LDiversityConfig();
    }

    public static com.google.privacy.dlp.v2beta1.PrivacyMetric.LDiversityConfig getDefaultInstance() {
      return DEFAULT_INSTANCE;
    }

    private static final com.google.protobuf.Parser<LDiversityConfig>
        PARSER = new com.google.protobuf.AbstractParser<LDiversityConfig>() {
      public LDiversityConfig parsePartialFrom(
          com.google.protobuf.CodedInputStream input,
          com.google.protobuf.ExtensionRegistryLite extensionRegistry)
          throws com.google.protobuf.InvalidProtocolBufferException {
        return new LDiversityConfig(input, extensionRegistry);
      }
    };

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

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

    public com.google.privacy.dlp.v2beta1.PrivacyMetric.LDiversityConfig getDefaultInstanceForType() {
      return DEFAULT_INSTANCE;
    }

  }

  private int typeCase_ = 0;
  private java.lang.Object type_;
  public enum TypeCase
      implements com.google.protobuf.Internal.EnumLite {
    NUMERICAL_STATS_CONFIG(1),
    CATEGORICAL_STATS_CONFIG(2),
    K_ANONYMITY_CONFIG(3),
    L_DIVERSITY_CONFIG(4),
    TYPE_NOT_SET(0);
    private final int value;
    private TypeCase(int value) {
      this.value = value;
    }
    /**
     * @deprecated Use {@link #forNumber(int)} instead.
     */
    @java.lang.Deprecated
    public static TypeCase valueOf(int value) {
      return forNumber(value);
    }

    public static TypeCase forNumber(int value) {
      switch (value) {
        case 1: return NUMERICAL_STATS_CONFIG;
        case 2: return CATEGORICAL_STATS_CONFIG;
        case 3: return K_ANONYMITY_CONFIG;
        case 4: return L_DIVERSITY_CONFIG;
        case 0: return TYPE_NOT_SET;
        default: return null;
      }
    }
    public int getNumber() {
      return this.value;
    }
  };

  public TypeCase
  getTypeCase() {
    return TypeCase.forNumber(
        typeCase_);
  }

  public static final int NUMERICAL_STATS_CONFIG_FIELD_NUMBER = 1;
  /**
   * <code>.google.privacy.dlp.v2beta1.PrivacyMetric.NumericalStatsConfig numerical_stats_config = 1;</code>
   */
  public boolean hasNumericalStatsConfig() {
    return typeCase_ == 1;
  }
  /**
   * <code>.google.privacy.dlp.v2beta1.PrivacyMetric.NumericalStatsConfig numerical_stats_config = 1;</code>
   */
  public com.google.privacy.dlp.v2beta1.PrivacyMetric.NumericalStatsConfig getNumericalStatsConfig() {
    if (typeCase_ == 1) {
       return (com.google.privacy.dlp.v2beta1.PrivacyMetric.NumericalStatsConfig) type_;
    }
    return com.google.privacy.dlp.v2beta1.PrivacyMetric.NumericalStatsConfig.getDefaultInstance();
  }
  /**
   * <code>.google.privacy.dlp.v2beta1.PrivacyMetric.NumericalStatsConfig numerical_stats_config = 1;</code>
   */
  public com.google.privacy.dlp.v2beta1.PrivacyMetric.NumericalStatsConfigOrBuilder getNumericalStatsConfigOrBuilder() {
    if (typeCase_ == 1) {
       return (com.google.privacy.dlp.v2beta1.PrivacyMetric.NumericalStatsConfig) type_;
    }
    return com.google.privacy.dlp.v2beta1.PrivacyMetric.NumericalStatsConfig.getDefaultInstance();
  }

  public static final int CATEGORICAL_STATS_CONFIG_FIELD_NUMBER = 2;
  /**
   * <code>.google.privacy.dlp.v2beta1.PrivacyMetric.CategoricalStatsConfig categorical_stats_config = 2;</code>
   */
  public boolean hasCategoricalStatsConfig() {
    return typeCase_ == 2;
  }
  /**
   * <code>.google.privacy.dlp.v2beta1.PrivacyMetric.CategoricalStatsConfig categorical_stats_config = 2;</code>
   */
  public com.google.privacy.dlp.v2beta1.PrivacyMetric.CategoricalStatsConfig getCategoricalStatsConfig() {
    if (typeCase_ == 2) {
       return (com.google.privacy.dlp.v2beta1.PrivacyMetric.CategoricalStatsConfig) type_;
    }
    return com.google.privacy.dlp.v2beta1.PrivacyMetric.CategoricalStatsConfig.getDefaultInstance();
  }
  /**
   * <code>.google.privacy.dlp.v2beta1.PrivacyMetric.CategoricalStatsConfig categorical_stats_config = 2;</code>
   */
  public com.google.privacy.dlp.v2beta1.PrivacyMetric.CategoricalStatsConfigOrBuilder getCategoricalStatsConfigOrBuilder() {
    if (typeCase_ == 2) {
       return (com.google.privacy.dlp.v2beta1.PrivacyMetric.CategoricalStatsConfig) type_;
    }
    return com.google.privacy.dlp.v2beta1.PrivacyMetric.CategoricalStatsConfig.getDefaultInstance();
  }

  public static final int K_ANONYMITY_CONFIG_FIELD_NUMBER = 3;
  /**
   * <code>.google.privacy.dlp.v2beta1.PrivacyMetric.KAnonymityConfig k_anonymity_config = 3;</code>
   */
  public boolean hasKAnonymityConfig() {
    return typeCase_ == 3;
  }
  /**
   * <code>.google.privacy.dlp.v2beta1.PrivacyMetric.KAnonymityConfig k_anonymity_config = 3;</code>
   */
  public com.google.privacy.dlp.v2beta1.PrivacyMetric.KAnonymityConfig getKAnonymityConfig() {
    if (typeCase_ == 3) {
       return (com.google.privacy.dlp.v2beta1.PrivacyMetric.KAnonymityConfig) type_;
    }
    return com.google.privacy.dlp.v2beta1.PrivacyMetric.KAnonymityConfig.getDefaultInstance();
  }
  /**
   * <code>.google.privacy.dlp.v2beta1.PrivacyMetric.KAnonymityConfig k_anonymity_config = 3;</code>
   */
  public com.google.privacy.dlp.v2beta1.PrivacyMetric.KAnonymityConfigOrBuilder getKAnonymityConfigOrBuilder() {
    if (typeCase_ == 3) {
       return (com.google.privacy.dlp.v2beta1.PrivacyMetric.KAnonymityConfig) type_;
    }
    return com.google.privacy.dlp.v2beta1.PrivacyMetric.KAnonymityConfig.getDefaultInstance();
  }

  public static final int L_DIVERSITY_CONFIG_FIELD_NUMBER = 4;
  /**
   * <code>.google.privacy.dlp.v2beta1.PrivacyMetric.LDiversityConfig l_diversity_config = 4;</code>
   */
  public boolean hasLDiversityConfig() {
    return typeCase_ == 4;
  }
  /**
   * <code>.google.privacy.dlp.v2beta1.PrivacyMetric.LDiversityConfig l_diversity_config = 4;</code>
   */
  public com.google.privacy.dlp.v2beta1.PrivacyMetric.LDiversityConfig getLDiversityConfig() {
    if (typeCase_ == 4) {
       return (com.google.privacy.dlp.v2beta1.PrivacyMetric.LDiversityConfig) type_;
    }
    return com.google.privacy.dlp.v2beta1.PrivacyMetric.LDiversityConfig.getDefaultInstance();
  }
  /**
   * <code>.google.privacy.dlp.v2beta1.PrivacyMetric.LDiversityConfig l_diversity_config = 4;</code>
   */
  public com.google.privacy.dlp.v2beta1.PrivacyMetric.LDiversityConfigOrBuilder getLDiversityConfigOrBuilder() {
    if (typeCase_ == 4) {
       return (com.google.privacy.dlp.v2beta1.PrivacyMetric.LDiversityConfig) type_;
    }
    return com.google.privacy.dlp.v2beta1.PrivacyMetric.LDiversityConfig.getDefaultInstance();
  }

  private byte memoizedIsInitialized = -1;
  public final boolean isInitialized() {
    byte isInitialized = memoizedIsInitialized;
    if (isInitialized == 1) return true;
    if (isInitialized == 0) return false;

    memoizedIsInitialized = 1;
    return true;
  }

  public void writeTo(com.google.protobuf.CodedOutputStream output)
                      throws java.io.IOException {
    if (typeCase_ == 1) {
      output.writeMessage(1, (com.google.privacy.dlp.v2beta1.PrivacyMetric.NumericalStatsConfig) type_);
    }
    if (typeCase_ == 2) {
      output.writeMessage(2, (com.google.privacy.dlp.v2beta1.PrivacyMetric.CategoricalStatsConfig) type_);
    }
    if (typeCase_ == 3) {
      output.writeMessage(3, (com.google.privacy.dlp.v2beta1.PrivacyMetric.KAnonymityConfig) type_);
    }
    if (typeCase_ == 4) {
      output.writeMessage(4, (com.google.privacy.dlp.v2beta1.PrivacyMetric.LDiversityConfig) type_);
    }
    unknownFields.writeTo(output);
  }

  public int getSerializedSize() {
    int size = memoizedSize;
    if (size != -1) return size;

    size = 0;
    if (typeCase_ == 1) {
      size += com.google.protobuf.CodedOutputStream
        .computeMessageSize(1, (com.google.privacy.dlp.v2beta1.PrivacyMetric.NumericalStatsConfig) type_);
    }
    if (typeCase_ == 2) {
      size += com.google.protobuf.CodedOutputStream
        .computeMessageSize(2, (com.google.privacy.dlp.v2beta1.PrivacyMetric.CategoricalStatsConfig) type_);
    }
    if (typeCase_ == 3) {
      size += com.google.protobuf.CodedOutputStream
        .computeMessageSize(3, (com.google.privacy.dlp.v2beta1.PrivacyMetric.KAnonymityConfig) type_);
    }
    if (typeCase_ == 4) {
      size += com.google.protobuf.CodedOutputStream
        .computeMessageSize(4, (com.google.privacy.dlp.v2beta1.PrivacyMetric.LDiversityConfig) type_);
    }
    size += unknownFields.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.privacy.dlp.v2beta1.PrivacyMetric)) {
      return super.equals(obj);
    }
    com.google.privacy.dlp.v2beta1.PrivacyMetric other = (com.google.privacy.dlp.v2beta1.PrivacyMetric) obj;

    boolean result = true;
    result = result && getTypeCase().equals(
        other.getTypeCase());
    if (!result) return false;
    switch (typeCase_) {
      case 1:
        result = result && getNumericalStatsConfig()
            .equals(other.getNumericalStatsConfig());
        break;
      case 2:
        result = result && getCategoricalStatsConfig()
            .equals(other.getCategoricalStatsConfig());
        break;
      case 3:
        result = result && getKAnonymityConfig()
            .equals(other.getKAnonymityConfig());
        break;
      case 4:
        result = result && getLDiversityConfig()
            .equals(other.getLDiversityConfig());
        break;
      case 0:
      default:
    }
    result = result && unknownFields.equals(other.unknownFields);
    return result;
  }

  @java.lang.Override
  public int hashCode() {
    if (memoizedHashCode != 0) {
      return memoizedHashCode;
    }
    int hash = 41;
    hash = (19 * hash) + getDescriptor().hashCode();
    switch (typeCase_) {
      case 1:
        hash = (37 * hash) + NUMERICAL_STATS_CONFIG_FIELD_NUMBER;
        hash = (53 * hash) + getNumericalStatsConfig().hashCode();
        break;
      case 2:
        hash = (37 * hash) + CATEGORICAL_STATS_CONFIG_FIELD_NUMBER;
        hash = (53 * hash) + getCategoricalStatsConfig().hashCode();
        break;
      case 3:
        hash = (37 * hash) + K_ANONYMITY_CONFIG_FIELD_NUMBER;
        hash = (53 * hash) + getKAnonymityConfig().hashCode();
        break;
      case 4:
        hash = (37 * hash) + L_DIVERSITY_CONFIG_FIELD_NUMBER;
        hash = (53 * hash) + getLDiversityConfig().hashCode();
        break;
      case 0:
      default:
    }
    hash = (29 * hash) + unknownFields.hashCode();
    memoizedHashCode = hash;
    return hash;
  }

  public static com.google.privacy.dlp.v2beta1.PrivacyMetric parseFrom(
      java.nio.ByteBuffer data)
      throws com.google.protobuf.InvalidProtocolBufferException {
    return PARSER.parseFrom(data);
  }
  public static com.google.privacy.dlp.v2beta1.PrivacyMetric parseFrom(
      java.nio.ByteBuffer data,
      com.google.protobuf.ExtensionRegistryLite extensionRegistry)
      throws com.google.protobuf.InvalidProtocolBufferException {
    return PARSER.parseFrom(data, extensionRegistry);
  }
  public static com.google.privacy.dlp.v2beta1.PrivacyMetric parseFrom(
      com.google.protobuf.ByteString data)
      throws com.google.protobuf.InvalidProtocolBufferException {
    return PARSER.parseFrom(data);
  }
  public static com.google.privacy.dlp.v2beta1.PrivacyMetric 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.privacy.dlp.v2beta1.PrivacyMetric parseFrom(byte[] data)
      throws com.google.protobuf.InvalidProtocolBufferException {
    return PARSER.parseFrom(data);
  }
  public static com.google.privacy.dlp.v2beta1.PrivacyMetric parseFrom(
      byte[] data,
      com.google.protobuf.ExtensionRegistryLite extensionRegistry)
      throws com.google.protobuf.InvalidProtocolBufferException {
    return PARSER.parseFrom(data, extensionRegistry);
  }
  public static com.google.privacy.dlp.v2beta1.PrivacyMetric parseFrom(java.io.InputStream input)
      throws java.io.IOException {
    return com.google.protobuf.GeneratedMessageV3
        .parseWithIOException(PARSER, input);
  }
  public static com.google.privacy.dlp.v2beta1.PrivacyMetric 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.privacy.dlp.v2beta1.PrivacyMetric parseDelimitedFrom(java.io.InputStream input)
      throws java.io.IOException {
    return com.google.protobuf.GeneratedMessageV3
        .parseDelimitedWithIOException(PARSER, input);
  }
  public static com.google.privacy.dlp.v2beta1.PrivacyMetric 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.privacy.dlp.v2beta1.PrivacyMetric parseFrom(
      com.google.protobuf.CodedInputStream input)
      throws java.io.IOException {
    return com.google.protobuf.GeneratedMessageV3
        .parseWithIOException(PARSER, input);
  }
  public static com.google.privacy.dlp.v2beta1.PrivacyMetric parseFrom(
      com.google.protobuf.CodedInputStream input,
      com.google.protobuf.ExtensionRegistryLite extensionRegistry)
      throws java.io.IOException {
    return com.google.protobuf.GeneratedMessageV3
        .parseWithIOException(PARSER, input, extensionRegistry);
  }

  public Builder newBuilderForType() { return newBuilder(); }
  public static Builder newBuilder() {
    return DEFAULT_INSTANCE.toBuilder();
  }
  public static Builder newBuilder(com.google.privacy.dlp.v2beta1.PrivacyMetric prototype) {
    return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype);
  }
  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>
   * Privacy metric to compute for reidentification risk analysis.
   * </pre>
   *
   * Protobuf type {@code google.privacy.dlp.v2beta1.PrivacyMetric}
   */
  public static final class Builder extends
      com.google.protobuf.GeneratedMessageV3.Builder<Builder> implements
      // @@protoc_insertion_point(builder_implements:google.privacy.dlp.v2beta1.PrivacyMetric)
      com.google.privacy.dlp.v2beta1.PrivacyMetricOrBuilder {
    public static final com.google.protobuf.Descriptors.Descriptor
        getDescriptor() {
      return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_PrivacyMetric_descriptor;
    }

    protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
        internalGetFieldAccessorTable() {
      return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_PrivacyMetric_fieldAccessorTable
          .ensureFieldAccessorsInitialized(
              com.google.privacy.dlp.v2beta1.PrivacyMetric.class, com.google.privacy.dlp.v2beta1.PrivacyMetric.Builder.class);
    }

    // Construct using com.google.privacy.dlp.v2beta1.PrivacyMetric.newBuilder()
    private Builder() {
      maybeForceBuilderInitialization();
    }

    private Builder(
        com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
      super(parent);
      maybeForceBuilderInitialization();
    }
    private void maybeForceBuilderInitialization() {
      if (com.google.protobuf.GeneratedMessageV3
              .alwaysUseFieldBuilders) {
      }
    }
    public Builder clear() {
      super.clear();
      typeCase_ = 0;
      type_ = null;
      return this;
    }

    public com.google.protobuf.Descriptors.Descriptor
        getDescriptorForType() {
      return com.google.privacy.dlp.v2beta1.DlpProto.internal_static_google_privacy_dlp_v2beta1_PrivacyMetric_descriptor;
    }

    public com.google.privacy.dlp.v2beta1.PrivacyMetric getDefaultInstanceForType() {
      return com.google.privacy.dlp.v2beta1.PrivacyMetric.getDefaultInstance();
    }

    public com.google.privacy.dlp.v2beta1.PrivacyMetric build() {
      com.google.privacy.dlp.v2beta1.PrivacyMetric result = buildPartial();
      if (!result.isInitialized()) {
        throw newUninitializedMessageException(result);
      }
      return result;
    }

    public com.google.privacy.dlp.v2beta1.PrivacyMetric buildPartial() {
      com.google.privacy.dlp.v2beta1.PrivacyMetric result = new com.google.privacy.dlp.v2beta1.PrivacyMetric(this);
      if (typeCase_ == 1) {
        if (numericalStatsConfigBuilder_ == null) {
          result.type_ = type_;
        } else {
          result.type_ = numericalStatsConfigBuilder_.build();
        }
      }
      if (typeCase_ == 2) {
        if (categoricalStatsConfigBuilder_ == null) {
          result.type_ = type_;
        } else {
          result.type_ = categoricalStatsConfigBuilder_.build();
        }
      }
      if (typeCase_ == 3) {
        if (kAnonymityConfigBuilder_ == null) {
          result.type_ = type_;
        } else {
          result.type_ = kAnonymityConfigBuilder_.build();
        }
      }
      if (typeCase_ == 4) {
        if (lDiversityConfigBuilder_ == null) {
          result.type_ = type_;
        } else {
          result.type_ = lDiversityConfigBuilder_.build();
        }
      }
      result.typeCase_ = typeCase_;
      onBuilt();
      return result;
    }

    public Builder clone() {
      return (Builder) super.clone();
    }
    public Builder setField(
        com.google.protobuf.Descriptors.FieldDescriptor field,
        java.lang.Object value) {
      return (Builder) super.setField(field, value);
    }
    public Builder clearField(
        com.google.protobuf.Descriptors.FieldDescriptor field) {
      return (Builder) super.clearField(field);
    }
    public Builder clearOneof(
        com.google.protobuf.Descriptors.OneofDescriptor oneof) {
      return (Builder) super.clearOneof(oneof);
    }
    public Builder setRepeatedField(
        com.google.protobuf.Descriptors.FieldDescriptor field,
        int index, java.lang.Object value) {
      return (Builder) super.setRepeatedField(field, index, value);
    }
    public Builder addRepeatedField(
        com.google.protobuf.Descriptors.FieldDescriptor field,
        java.lang.Object value) {
      return (Builder) super.addRepeatedField(field, value);
    }
    public Builder mergeFrom(com.google.protobuf.Message other) {
      if (other instanceof com.google.privacy.dlp.v2beta1.PrivacyMetric) {
        return mergeFrom((com.google.privacy.dlp.v2beta1.PrivacyMetric)other);
      } else {
        super.mergeFrom(other);
        return this;
      }
    }

    public Builder mergeFrom(com.google.privacy.dlp.v2beta1.PrivacyMetric other) {
      if (other == com.google.privacy.dlp.v2beta1.PrivacyMetric.getDefaultInstance()) return this;
      switch (other.getTypeCase()) {
        case NUMERICAL_STATS_CONFIG: {
          mergeNumericalStatsConfig(other.getNumericalStatsConfig());
          break;
        }
        case CATEGORICAL_STATS_CONFIG: {
          mergeCategoricalStatsConfig(other.getCategoricalStatsConfig());
          break;
        }
        case K_ANONYMITY_CONFIG: {
          mergeKAnonymityConfig(other.getKAnonymityConfig());
          break;
        }
        case L_DIVERSITY_CONFIG: {
          mergeLDiversityConfig(other.getLDiversityConfig());
          break;
        }
        case TYPE_NOT_SET: {
          break;
        }
      }
      this.mergeUnknownFields(other.unknownFields);
      onChanged();
      return this;
    }

    public final boolean isInitialized() {
      return true;
    }

    public Builder mergeFrom(
        com.google.protobuf.CodedInputStream input,
        com.google.protobuf.ExtensionRegistryLite extensionRegistry)
        throws java.io.IOException {
      com.google.privacy.dlp.v2beta1.PrivacyMetric parsedMessage = null;
      try {
        parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry);
      } catch (com.google.protobuf.InvalidProtocolBufferException e) {
        parsedMessage = (com.google.privacy.dlp.v2beta1.PrivacyMetric) e.getUnfinishedMessage();
        throw e.unwrapIOException();
      } finally {
        if (parsedMessage != null) {
          mergeFrom(parsedMessage);
        }
      }
      return this;
    }
    private int typeCase_ = 0;
    private java.lang.Object type_;
    public TypeCase
        getTypeCase() {
      return TypeCase.forNumber(
          typeCase_);
    }

    public Builder clearType() {
      typeCase_ = 0;
      type_ = null;
      onChanged();
      return this;
    }


    private com.google.protobuf.SingleFieldBuilderV3<
        com.google.privacy.dlp.v2beta1.PrivacyMetric.NumericalStatsConfig, com.google.privacy.dlp.v2beta1.PrivacyMetric.NumericalStatsConfig.Builder, com.google.privacy.dlp.v2beta1.PrivacyMetric.NumericalStatsConfigOrBuilder> numericalStatsConfigBuilder_;
    /**
     * <code>.google.privacy.dlp.v2beta1.PrivacyMetric.NumericalStatsConfig numerical_stats_config = 1;</code>
     */
    public boolean hasNumericalStatsConfig() {
      return typeCase_ == 1;
    }
    /**
     * <code>.google.privacy.dlp.v2beta1.PrivacyMetric.NumericalStatsConfig numerical_stats_config = 1;</code>
     */
    public com.google.privacy.dlp.v2beta1.PrivacyMetric.NumericalStatsConfig getNumericalStatsConfig() {
      if (numericalStatsConfigBuilder_ == null) {
        if (typeCase_ == 1) {
          return (com.google.privacy.dlp.v2beta1.PrivacyMetric.NumericalStatsConfig) type_;
        }
        return com.google.privacy.dlp.v2beta1.PrivacyMetric.NumericalStatsConfig.getDefaultInstance();
      } else {
        if (typeCase_ == 1) {
          return numericalStatsConfigBuilder_.getMessage();
        }
        return com.google.privacy.dlp.v2beta1.PrivacyMetric.NumericalStatsConfig.getDefaultInstance();
      }
    }
    /**
     * <code>.google.privacy.dlp.v2beta1.PrivacyMetric.NumericalStatsConfig numerical_stats_config = 1;</code>
     */
    public Builder setNumericalStatsConfig(com.google.privacy.dlp.v2beta1.PrivacyMetric.NumericalStatsConfig value) {
      if (numericalStatsConfigBuilder_ == null) {
        if (value == null) {
          throw new NullPointerException();
        }
        type_ = value;
        onChanged();
      } else {
        numericalStatsConfigBuilder_.setMessage(value);
      }
      typeCase_ = 1;
      return this;
    }
    /**
     * <code>.google.privacy.dlp.v2beta1.PrivacyMetric.NumericalStatsConfig numerical_stats_config = 1;</code>
     */
    public Builder setNumericalStatsConfig(
        com.google.privacy.dlp.v2beta1.PrivacyMetric.NumericalStatsConfig.Builder builderForValue) {
      if (numericalStatsConfigBuilder_ == null) {
        type_ = builderForValue.build();
        onChanged();
      } else {
        numericalStatsConfigBuilder_.setMessage(builderForValue.build());
      }
      typeCase_ = 1;
      return this;
    }
    /**
     * <code>.google.privacy.dlp.v2beta1.PrivacyMetric.NumericalStatsConfig numerical_stats_config = 1;</code>
     */
    public Builder mergeNumericalStatsConfig(com.google.privacy.dlp.v2beta1.PrivacyMetric.NumericalStatsConfig value) {
      if (numericalStatsConfigBuilder_ == null) {
        if (typeCase_ == 1 &&
            type_ != com.google.privacy.dlp.v2beta1.PrivacyMetric.NumericalStatsConfig.getDefaultInstance()) {
          type_ = com.google.privacy.dlp.v2beta1.PrivacyMetric.NumericalStatsConfig.newBuilder((com.google.privacy.dlp.v2beta1.PrivacyMetric.NumericalStatsConfig) type_)
              .mergeFrom(value).buildPartial();
        } else {
          type_ = value;
        }
        onChanged();
      } else {
        if (typeCase_ == 1) {
          numericalStatsConfigBuilder_.mergeFrom(value);
        }
        numericalStatsConfigBuilder_.setMessage(value);
      }
      typeCase_ = 1;
      return this;
    }
    /**
     * <code>.google.privacy.dlp.v2beta1.PrivacyMetric.NumericalStatsConfig numerical_stats_config = 1;</code>
     */
    public Builder clearNumericalStatsConfig() {
      if (numericalStatsConfigBuilder_ == null) {
        if (typeCase_ == 1) {
          typeCase_ = 0;
          type_ = null;
          onChanged();
        }
      } else {
        if (typeCase_ == 1) {
          typeCase_ = 0;
          type_ = null;
        }
        numericalStatsConfigBuilder_.clear();
      }
      return this;
    }
    /**
     * <code>.google.privacy.dlp.v2beta1.PrivacyMetric.NumericalStatsConfig numerical_stats_config = 1;</code>
     */
    public com.google.privacy.dlp.v2beta1.PrivacyMetric.NumericalStatsConfig.Builder getNumericalStatsConfigBuilder() {
      return getNumericalStatsConfigFieldBuilder().getBuilder();
    }
    /**
     * <code>.google.privacy.dlp.v2beta1.PrivacyMetric.NumericalStatsConfig numerical_stats_config = 1;</code>
     */
    public com.google.privacy.dlp.v2beta1.PrivacyMetric.NumericalStatsConfigOrBuilder getNumericalStatsConfigOrBuilder() {
      if ((typeCase_ == 1) && (numericalStatsConfigBuilder_ != null)) {
        return numericalStatsConfigBuilder_.getMessageOrBuilder();
      } else {
        if (typeCase_ == 1) {
          return (com.google.privacy.dlp.v2beta1.PrivacyMetric.NumericalStatsConfig) type_;
        }
        return com.google.privacy.dlp.v2beta1.PrivacyMetric.NumericalStatsConfig.getDefaultInstance();
      }
    }
    /**
     * <code>.google.privacy.dlp.v2beta1.PrivacyMetric.NumericalStatsConfig numerical_stats_config = 1;</code>
     */
    private com.google.protobuf.SingleFieldBuilderV3<
        com.google.privacy.dlp.v2beta1.PrivacyMetric.NumericalStatsConfig, com.google.privacy.dlp.v2beta1.PrivacyMetric.NumericalStatsConfig.Builder, com.google.privacy.dlp.v2beta1.PrivacyMetric.NumericalStatsConfigOrBuilder> 
        getNumericalStatsConfigFieldBuilder() {
      if (numericalStatsConfigBuilder_ == null) {
        if (!(typeCase_ == 1)) {
          type_ = com.google.privacy.dlp.v2beta1.PrivacyMetric.NumericalStatsConfig.getDefaultInstance();
        }
        numericalStatsConfigBuilder_ = new com.google.protobuf.SingleFieldBuilderV3<
            com.google.privacy.dlp.v2beta1.PrivacyMetric.NumericalStatsConfig, com.google.privacy.dlp.v2beta1.PrivacyMetric.NumericalStatsConfig.Builder, com.google.privacy.dlp.v2beta1.PrivacyMetric.NumericalStatsConfigOrBuilder>(
                (com.google.privacy.dlp.v2beta1.PrivacyMetric.NumericalStatsConfig) type_,
                getParentForChildren(),
                isClean());
        type_ = null;
      }
      typeCase_ = 1;
      onChanged();;
      return numericalStatsConfigBuilder_;
    }

    private com.google.protobuf.SingleFieldBuilderV3<
        com.google.privacy.dlp.v2beta1.PrivacyMetric.CategoricalStatsConfig, com.google.privacy.dlp.v2beta1.PrivacyMetric.CategoricalStatsConfig.Builder, com.google.privacy.dlp.v2beta1.PrivacyMetric.CategoricalStatsConfigOrBuilder> categoricalStatsConfigBuilder_;
    /**
     * <code>.google.privacy.dlp.v2beta1.PrivacyMetric.CategoricalStatsConfig categorical_stats_config = 2;</code>
     */
    public boolean hasCategoricalStatsConfig() {
      return typeCase_ == 2;
    }
    /**
     * <code>.google.privacy.dlp.v2beta1.PrivacyMetric.CategoricalStatsConfig categorical_stats_config = 2;</code>
     */
    public com.google.privacy.dlp.v2beta1.PrivacyMetric.CategoricalStatsConfig getCategoricalStatsConfig() {
      if (categoricalStatsConfigBuilder_ == null) {
        if (typeCase_ == 2) {
          return (com.google.privacy.dlp.v2beta1.PrivacyMetric.CategoricalStatsConfig) type_;
        }
        return com.google.privacy.dlp.v2beta1.PrivacyMetric.CategoricalStatsConfig.getDefaultInstance();
      } else {
        if (typeCase_ == 2) {
          return categoricalStatsConfigBuilder_.getMessage();
        }
        return com.google.privacy.dlp.v2beta1.PrivacyMetric.CategoricalStatsConfig.getDefaultInstance();
      }
    }
    /**
     * <code>.google.privacy.dlp.v2beta1.PrivacyMetric.CategoricalStatsConfig categorical_stats_config = 2;</code>
     */
    public Builder setCategoricalStatsConfig(com.google.privacy.dlp.v2beta1.PrivacyMetric.CategoricalStatsConfig value) {
      if (categoricalStatsConfigBuilder_ == null) {
        if (value == null) {
          throw new NullPointerException();
        }
        type_ = value;
        onChanged();
      } else {
        categoricalStatsConfigBuilder_.setMessage(value);
      }
      typeCase_ = 2;
      return this;
    }
    /**
     * <code>.google.privacy.dlp.v2beta1.PrivacyMetric.CategoricalStatsConfig categorical_stats_config = 2;</code>
     */
    public Builder setCategoricalStatsConfig(
        com.google.privacy.dlp.v2beta1.PrivacyMetric.CategoricalStatsConfig.Builder builderForValue) {
      if (categoricalStatsConfigBuilder_ == null) {
        type_ = builderForValue.build();
        onChanged();
      } else {
        categoricalStatsConfigBuilder_.setMessage(builderForValue.build());
      }
      typeCase_ = 2;
      return this;
    }
    /**
     * <code>.google.privacy.dlp.v2beta1.PrivacyMetric.CategoricalStatsConfig categorical_stats_config = 2;</code>
     */
    public Builder mergeCategoricalStatsConfig(com.google.privacy.dlp.v2beta1.PrivacyMetric.CategoricalStatsConfig value) {
      if (categoricalStatsConfigBuilder_ == null) {
        if (typeCase_ == 2 &&
            type_ != com.google.privacy.dlp.v2beta1.PrivacyMetric.CategoricalStatsConfig.getDefaultInstance()) {
          type_ = com.google.privacy.dlp.v2beta1.PrivacyMetric.CategoricalStatsConfig.newBuilder((com.google.privacy.dlp.v2beta1.PrivacyMetric.CategoricalStatsConfig) type_)
              .mergeFrom(value).buildPartial();
        } else {
          type_ = value;
        }
        onChanged();
      } else {
        if (typeCase_ == 2) {
          categoricalStatsConfigBuilder_.mergeFrom(value);
        }
        categoricalStatsConfigBuilder_.setMessage(value);
      }
      typeCase_ = 2;
      return this;
    }
    /**
     * <code>.google.privacy.dlp.v2beta1.PrivacyMetric.CategoricalStatsConfig categorical_stats_config = 2;</code>
     */
    public Builder clearCategoricalStatsConfig() {
      if (categoricalStatsConfigBuilder_ == null) {
        if (typeCase_ == 2) {
          typeCase_ = 0;
          type_ = null;
          onChanged();
        }
      } else {
        if (typeCase_ == 2) {
          typeCase_ = 0;
          type_ = null;
        }
        categoricalStatsConfigBuilder_.clear();
      }
      return this;
    }
    /**
     * <code>.google.privacy.dlp.v2beta1.PrivacyMetric.CategoricalStatsConfig categorical_stats_config = 2;</code>
     */
    public com.google.privacy.dlp.v2beta1.PrivacyMetric.CategoricalStatsConfig.Builder getCategoricalStatsConfigBuilder() {
      return getCategoricalStatsConfigFieldBuilder().getBuilder();
    }
    /**
     * <code>.google.privacy.dlp.v2beta1.PrivacyMetric.CategoricalStatsConfig categorical_stats_config = 2;</code>
     */
    public com.google.privacy.dlp.v2beta1.PrivacyMetric.CategoricalStatsConfigOrBuilder getCategoricalStatsConfigOrBuilder() {
      if ((typeCase_ == 2) && (categoricalStatsConfigBuilder_ != null)) {
        return categoricalStatsConfigBuilder_.getMessageOrBuilder();
      } else {
        if (typeCase_ == 2) {
          return (com.google.privacy.dlp.v2beta1.PrivacyMetric.CategoricalStatsConfig) type_;
        }
        return com.google.privacy.dlp.v2beta1.PrivacyMetric.CategoricalStatsConfig.getDefaultInstance();
      }
    }
    /**
     * <code>.google.privacy.dlp.v2beta1.PrivacyMetric.CategoricalStatsConfig categorical_stats_config = 2;</code>
     */
    private com.google.protobuf.SingleFieldBuilderV3<
        com.google.privacy.dlp.v2beta1.PrivacyMetric.CategoricalStatsConfig, com.google.privacy.dlp.v2beta1.PrivacyMetric.CategoricalStatsConfig.Builder, com.google.privacy.dlp.v2beta1.PrivacyMetric.CategoricalStatsConfigOrBuilder> 
        getCategoricalStatsConfigFieldBuilder() {
      if (categoricalStatsConfigBuilder_ == null) {
        if (!(typeCase_ == 2)) {
          type_ = com.google.privacy.dlp.v2beta1.PrivacyMetric.CategoricalStatsConfig.getDefaultInstance();
        }
        categoricalStatsConfigBuilder_ = new com.google.protobuf.SingleFieldBuilderV3<
            com.google.privacy.dlp.v2beta1.PrivacyMetric.CategoricalStatsConfig, com.google.privacy.dlp.v2beta1.PrivacyMetric.CategoricalStatsConfig.Builder, com.google.privacy.dlp.v2beta1.PrivacyMetric.CategoricalStatsConfigOrBuilder>(
                (com.google.privacy.dlp.v2beta1.PrivacyMetric.CategoricalStatsConfig) type_,
                getParentForChildren(),
                isClean());
        type_ = null;
      }
      typeCase_ = 2;
      onChanged();;
      return categoricalStatsConfigBuilder_;
    }

    private com.google.protobuf.SingleFieldBuilderV3<
        com.google.privacy.dlp.v2beta1.PrivacyMetric.KAnonymityConfig, com.google.privacy.dlp.v2beta1.PrivacyMetric.KAnonymityConfig.Builder, com.google.privacy.dlp.v2beta1.PrivacyMetric.KAnonymityConfigOrBuilder> kAnonymityConfigBuilder_;
    /**
     * <code>.google.privacy.dlp.v2beta1.PrivacyMetric.KAnonymityConfig k_anonymity_config = 3;</code>
     */
    public boolean hasKAnonymityConfig() {
      return typeCase_ == 3;
    }
    /**
     * <code>.google.privacy.dlp.v2beta1.PrivacyMetric.KAnonymityConfig k_anonymity_config = 3;</code>
     */
    public com.google.privacy.dlp.v2beta1.PrivacyMetric.KAnonymityConfig getKAnonymityConfig() {
      if (kAnonymityConfigBuilder_ == null) {
        if (typeCase_ == 3) {
          return (com.google.privacy.dlp.v2beta1.PrivacyMetric.KAnonymityConfig) type_;
        }
        return com.google.privacy.dlp.v2beta1.PrivacyMetric.KAnonymityConfig.getDefaultInstance();
      } else {
        if (typeCase_ == 3) {
          return kAnonymityConfigBuilder_.getMessage();
        }
        return com.google.privacy.dlp.v2beta1.PrivacyMetric.KAnonymityConfig.getDefaultInstance();
      }
    }
    /**
     * <code>.google.privacy.dlp.v2beta1.PrivacyMetric.KAnonymityConfig k_anonymity_config = 3;</code>
     */
    public Builder setKAnonymityConfig(com.google.privacy.dlp.v2beta1.PrivacyMetric.KAnonymityConfig value) {
      if (kAnonymityConfigBuilder_ == null) {
        if (value == null) {
          throw new NullPointerException();
        }
        type_ = value;
        onChanged();
      } else {
        kAnonymityConfigBuilder_.setMessage(value);
      }
      typeCase_ = 3;
      return this;
    }
    /**
     * <code>.google.privacy.dlp.v2beta1.PrivacyMetric.KAnonymityConfig k_anonymity_config = 3;</code>
     */
    public Builder setKAnonymityConfig(
        com.google.privacy.dlp.v2beta1.PrivacyMetric.KAnonymityConfig.Builder builderForValue) {
      if (kAnonymityConfigBuilder_ == null) {
        type_ = builderForValue.build();
        onChanged();
      } else {
        kAnonymityConfigBuilder_.setMessage(builderForValue.build());
      }
      typeCase_ = 3;
      return this;
    }
    /**
     * <code>.google.privacy.dlp.v2beta1.PrivacyMetric.KAnonymityConfig k_anonymity_config = 3;</code>
     */
    public Builder mergeKAnonymityConfig(com.google.privacy.dlp.v2beta1.PrivacyMetric.KAnonymityConfig value) {
      if (kAnonymityConfigBuilder_ == null) {
        if (typeCase_ == 3 &&
            type_ != com.google.privacy.dlp.v2beta1.PrivacyMetric.KAnonymityConfig.getDefaultInstance()) {
          type_ = com.google.privacy.dlp.v2beta1.PrivacyMetric.KAnonymityConfig.newBuilder((com.google.privacy.dlp.v2beta1.PrivacyMetric.KAnonymityConfig) type_)
              .mergeFrom(value).buildPartial();
        } else {
          type_ = value;
        }
        onChanged();
      } else {
        if (typeCase_ == 3) {
          kAnonymityConfigBuilder_.mergeFrom(value);
        }
        kAnonymityConfigBuilder_.setMessage(value);
      }
      typeCase_ = 3;
      return this;
    }
    /**
     * <code>.google.privacy.dlp.v2beta1.PrivacyMetric.KAnonymityConfig k_anonymity_config = 3;</code>
     */
    public Builder clearKAnonymityConfig() {
      if (kAnonymityConfigBuilder_ == null) {
        if (typeCase_ == 3) {
          typeCase_ = 0;
          type_ = null;
          onChanged();
        }
      } else {
        if (typeCase_ == 3) {
          typeCase_ = 0;
          type_ = null;
        }
        kAnonymityConfigBuilder_.clear();
      }
      return this;
    }
    /**
     * <code>.google.privacy.dlp.v2beta1.PrivacyMetric.KAnonymityConfig k_anonymity_config = 3;</code>
     */
    public com.google.privacy.dlp.v2beta1.PrivacyMetric.KAnonymityConfig.Builder getKAnonymityConfigBuilder() {
      return getKAnonymityConfigFieldBuilder().getBuilder();
    }
    /**
     * <code>.google.privacy.dlp.v2beta1.PrivacyMetric.KAnonymityConfig k_anonymity_config = 3;</code>
     */
    public com.google.privacy.dlp.v2beta1.PrivacyMetric.KAnonymityConfigOrBuilder getKAnonymityConfigOrBuilder() {
      if ((typeCase_ == 3) && (kAnonymityConfigBuilder_ != null)) {
        return kAnonymityConfigBuilder_.getMessageOrBuilder();
      } else {
        if (typeCase_ == 3) {
          return (com.google.privacy.dlp.v2beta1.PrivacyMetric.KAnonymityConfig) type_;
        }
        return com.google.privacy.dlp.v2beta1.PrivacyMetric.KAnonymityConfig.getDefaultInstance();
      }
    }
    /**
     * <code>.google.privacy.dlp.v2beta1.PrivacyMetric.KAnonymityConfig k_anonymity_config = 3;</code>
     */
    private com.google.protobuf.SingleFieldBuilderV3<
        com.google.privacy.dlp.v2beta1.PrivacyMetric.KAnonymityConfig, com.google.privacy.dlp.v2beta1.PrivacyMetric.KAnonymityConfig.Builder, com.google.privacy.dlp.v2beta1.PrivacyMetric.KAnonymityConfigOrBuilder> 
        getKAnonymityConfigFieldBuilder() {
      if (kAnonymityConfigBuilder_ == null) {
        if (!(typeCase_ == 3)) {
          type_ = com.google.privacy.dlp.v2beta1.PrivacyMetric.KAnonymityConfig.getDefaultInstance();
        }
        kAnonymityConfigBuilder_ = new com.google.protobuf.SingleFieldBuilderV3<
            com.google.privacy.dlp.v2beta1.PrivacyMetric.KAnonymityConfig, com.google.privacy.dlp.v2beta1.PrivacyMetric.KAnonymityConfig.Builder, com.google.privacy.dlp.v2beta1.PrivacyMetric.KAnonymityConfigOrBuilder>(
                (com.google.privacy.dlp.v2beta1.PrivacyMetric.KAnonymityConfig) type_,
                getParentForChildren(),
                isClean());
        type_ = null;
      }
      typeCase_ = 3;
      onChanged();;
      return kAnonymityConfigBuilder_;
    }

    private com.google.protobuf.SingleFieldBuilderV3<
        com.google.privacy.dlp.v2beta1.PrivacyMetric.LDiversityConfig, com.google.privacy.dlp.v2beta1.PrivacyMetric.LDiversityConfig.Builder, com.google.privacy.dlp.v2beta1.PrivacyMetric.LDiversityConfigOrBuilder> lDiversityConfigBuilder_;
    /**
     * <code>.google.privacy.dlp.v2beta1.PrivacyMetric.LDiversityConfig l_diversity_config = 4;</code>
     */
    public boolean hasLDiversityConfig() {
      return typeCase_ == 4;
    }
    /**
     * <code>.google.privacy.dlp.v2beta1.PrivacyMetric.LDiversityConfig l_diversity_config = 4;</code>
     */
    public com.google.privacy.dlp.v2beta1.PrivacyMetric.LDiversityConfig getLDiversityConfig() {
      if (lDiversityConfigBuilder_ == null) {
        if (typeCase_ == 4) {
          return (com.google.privacy.dlp.v2beta1.PrivacyMetric.LDiversityConfig) type_;
        }
        return com.google.privacy.dlp.v2beta1.PrivacyMetric.LDiversityConfig.getDefaultInstance();
      } else {
        if (typeCase_ == 4) {
          return lDiversityConfigBuilder_.getMessage();
        }
        return com.google.privacy.dlp.v2beta1.PrivacyMetric.LDiversityConfig.getDefaultInstance();
      }
    }
    /**
     * <code>.google.privacy.dlp.v2beta1.PrivacyMetric.LDiversityConfig l_diversity_config = 4;</code>
     */
    public Builder setLDiversityConfig(com.google.privacy.dlp.v2beta1.PrivacyMetric.LDiversityConfig value) {
      if (lDiversityConfigBuilder_ == null) {
        if (value == null) {
          throw new NullPointerException();
        }
        type_ = value;
        onChanged();
      } else {
        lDiversityConfigBuilder_.setMessage(value);
      }
      typeCase_ = 4;
      return this;
    }
    /**
     * <code>.google.privacy.dlp.v2beta1.PrivacyMetric.LDiversityConfig l_diversity_config = 4;</code>
     */
    public Builder setLDiversityConfig(
        com.google.privacy.dlp.v2beta1.PrivacyMetric.LDiversityConfig.Builder builderForValue) {
      if (lDiversityConfigBuilder_ == null) {
        type_ = builderForValue.build();
        onChanged();
      } else {
        lDiversityConfigBuilder_.setMessage(builderForValue.build());
      }
      typeCase_ = 4;
      return this;
    }
    /**
     * <code>.google.privacy.dlp.v2beta1.PrivacyMetric.LDiversityConfig l_diversity_config = 4;</code>
     */
    public Builder mergeLDiversityConfig(com.google.privacy.dlp.v2beta1.PrivacyMetric.LDiversityConfig value) {
      if (lDiversityConfigBuilder_ == null) {
        if (typeCase_ == 4 &&
            type_ != com.google.privacy.dlp.v2beta1.PrivacyMetric.LDiversityConfig.getDefaultInstance()) {
          type_ = com.google.privacy.dlp.v2beta1.PrivacyMetric.LDiversityConfig.newBuilder((com.google.privacy.dlp.v2beta1.PrivacyMetric.LDiversityConfig) type_)
              .mergeFrom(value).buildPartial();
        } else {
          type_ = value;
        }
        onChanged();
      } else {
        if (typeCase_ == 4) {
          lDiversityConfigBuilder_.mergeFrom(value);
        }
        lDiversityConfigBuilder_.setMessage(value);
      }
      typeCase_ = 4;
      return this;
    }
    /**
     * <code>.google.privacy.dlp.v2beta1.PrivacyMetric.LDiversityConfig l_diversity_config = 4;</code>
     */
    public Builder clearLDiversityConfig() {
      if (lDiversityConfigBuilder_ == null) {
        if (typeCase_ == 4) {
          typeCase_ = 0;
          type_ = null;
          onChanged();
        }
      } else {
        if (typeCase_ == 4) {
          typeCase_ = 0;
          type_ = null;
        }
        lDiversityConfigBuilder_.clear();
      }
      return this;
    }
    /**
     * <code>.google.privacy.dlp.v2beta1.PrivacyMetric.LDiversityConfig l_diversity_config = 4;</code>
     */
    public com.google.privacy.dlp.v2beta1.PrivacyMetric.LDiversityConfig.Builder getLDiversityConfigBuilder() {
      return getLDiversityConfigFieldBuilder().getBuilder();
    }
    /**
     * <code>.google.privacy.dlp.v2beta1.PrivacyMetric.LDiversityConfig l_diversity_config = 4;</code>
     */
    public com.google.privacy.dlp.v2beta1.PrivacyMetric.LDiversityConfigOrBuilder getLDiversityConfigOrBuilder() {
      if ((typeCase_ == 4) && (lDiversityConfigBuilder_ != null)) {
        return lDiversityConfigBuilder_.getMessageOrBuilder();
      } else {
        if (typeCase_ == 4) {
          return (com.google.privacy.dlp.v2beta1.PrivacyMetric.LDiversityConfig) type_;
        }
        return com.google.privacy.dlp.v2beta1.PrivacyMetric.LDiversityConfig.getDefaultInstance();
      }
    }
    /**
     * <code>.google.privacy.dlp.v2beta1.PrivacyMetric.LDiversityConfig l_diversity_config = 4;</code>
     */
    private com.google.protobuf.SingleFieldBuilderV3<
        com.google.privacy.dlp.v2beta1.PrivacyMetric.LDiversityConfig, com.google.privacy.dlp.v2beta1.PrivacyMetric.LDiversityConfig.Builder, com.google.privacy.dlp.v2beta1.PrivacyMetric.LDiversityConfigOrBuilder> 
        getLDiversityConfigFieldBuilder() {
      if (lDiversityConfigBuilder_ == null) {
        if (!(typeCase_ == 4)) {
          type_ = com.google.privacy.dlp.v2beta1.PrivacyMetric.LDiversityConfig.getDefaultInstance();
        }
        lDiversityConfigBuilder_ = new com.google.protobuf.SingleFieldBuilderV3<
            com.google.privacy.dlp.v2beta1.PrivacyMetric.LDiversityConfig, com.google.privacy.dlp.v2beta1.PrivacyMetric.LDiversityConfig.Builder, com.google.privacy.dlp.v2beta1.PrivacyMetric.LDiversityConfigOrBuilder>(
                (com.google.privacy.dlp.v2beta1.PrivacyMetric.LDiversityConfig) type_,
                getParentForChildren(),
                isClean());
        type_ = null;
      }
      typeCase_ = 4;
      onChanged();;
      return lDiversityConfigBuilder_;
    }
    public final Builder setUnknownFields(
        final com.google.protobuf.UnknownFieldSet unknownFields) {
      return super.setUnknownFieldsProto3(unknownFields);
    }

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


    // @@protoc_insertion_point(builder_scope:google.privacy.dlp.v2beta1.PrivacyMetric)
  }

  // @@protoc_insertion_point(class_scope:google.privacy.dlp.v2beta1.PrivacyMetric)
  private static final com.google.privacy.dlp.v2beta1.PrivacyMetric DEFAULT_INSTANCE;
  static {
    DEFAULT_INSTANCE = new com.google.privacy.dlp.v2beta1.PrivacyMetric();
  }

  public static com.google.privacy.dlp.v2beta1.PrivacyMetric getDefaultInstance() {
    return DEFAULT_INSTANCE;
  }

  private static final com.google.protobuf.Parser<PrivacyMetric>
      PARSER = new com.google.protobuf.AbstractParser<PrivacyMetric>() {
    public PrivacyMetric parsePartialFrom(
        com.google.protobuf.CodedInputStream input,
        com.google.protobuf.ExtensionRegistryLite extensionRegistry)
        throws com.google.protobuf.InvalidProtocolBufferException {
      return new PrivacyMetric(input, extensionRegistry);
    }
  };

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

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

  public com.google.privacy.dlp.v2beta1.PrivacyMetric getDefaultInstanceForType() {
    return DEFAULT_INSTANCE;
  }

}

