Class DataPolicy.Builder

java.lang.Object
com.google.protobuf.AbstractMessageLite.Builder
com.google.protobuf.AbstractMessage.Builder<BuilderT>
com.google.protobuf.GeneratedMessage.Builder<DataPolicy.Builder>
com.google.cloud.bigquery.datapolicies.v1.DataPolicy.Builder
All Implemented Interfaces:
DataPolicyOrBuilder, com.google.protobuf.Message.Builder, com.google.protobuf.MessageLite.Builder, com.google.protobuf.MessageLiteOrBuilder, com.google.protobuf.MessageOrBuilder, Cloneable
Enclosing class:
DataPolicy

public static final class DataPolicy.Builder extends com.google.protobuf.GeneratedMessage.Builder<DataPolicy.Builder> implements DataPolicyOrBuilder
 Represents the label-policy binding.
 
Protobuf type google.cloud.bigquery.datapolicies.v1.DataPolicy
  • Method Details

    • getDescriptor

      public static final com.google.protobuf.Descriptors.Descriptor getDescriptor()
    • internalGetFieldAccessorTable

      protected com.google.protobuf.GeneratedMessage.FieldAccessorTable internalGetFieldAccessorTable()
      Specified by:
      internalGetFieldAccessorTable in class com.google.protobuf.GeneratedMessage.Builder<DataPolicy.Builder>
    • clear

      public DataPolicy.Builder clear()
      Specified by:
      clear in interface com.google.protobuf.Message.Builder
      Specified by:
      clear in interface com.google.protobuf.MessageLite.Builder
      Overrides:
      clear in class com.google.protobuf.GeneratedMessage.Builder<DataPolicy.Builder>
    • getDescriptorForType

      public com.google.protobuf.Descriptors.Descriptor getDescriptorForType()
      Specified by:
      getDescriptorForType in interface com.google.protobuf.Message.Builder
      Specified by:
      getDescriptorForType in interface com.google.protobuf.MessageOrBuilder
      Overrides:
      getDescriptorForType in class com.google.protobuf.GeneratedMessage.Builder<DataPolicy.Builder>
    • getDefaultInstanceForType

      public DataPolicy getDefaultInstanceForType()
      Specified by:
      getDefaultInstanceForType in interface com.google.protobuf.MessageLiteOrBuilder
      Specified by:
      getDefaultInstanceForType in interface com.google.protobuf.MessageOrBuilder
    • build

      public DataPolicy build()
      Specified by:
      build in interface com.google.protobuf.Message.Builder
      Specified by:
      build in interface com.google.protobuf.MessageLite.Builder
    • buildPartial

      public DataPolicy buildPartial()
      Specified by:
      buildPartial in interface com.google.protobuf.Message.Builder
      Specified by:
      buildPartial in interface com.google.protobuf.MessageLite.Builder
    • mergeFrom

      public DataPolicy.Builder mergeFrom(com.google.protobuf.Message other)
      Specified by:
      mergeFrom in interface com.google.protobuf.Message.Builder
      Overrides:
      mergeFrom in class com.google.protobuf.AbstractMessage.Builder<DataPolicy.Builder>
    • mergeFrom

      public DataPolicy.Builder mergeFrom(DataPolicy other)
    • isInitialized

      public final boolean isInitialized()
      Specified by:
      isInitialized in interface com.google.protobuf.MessageLiteOrBuilder
      Overrides:
      isInitialized in class com.google.protobuf.GeneratedMessage.Builder<DataPolicy.Builder>
    • mergeFrom

      public DataPolicy.Builder mergeFrom(com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws IOException
      Specified by:
      mergeFrom in interface com.google.protobuf.Message.Builder
      Specified by:
      mergeFrom in interface com.google.protobuf.MessageLite.Builder
      Overrides:
      mergeFrom in class com.google.protobuf.AbstractMessage.Builder<DataPolicy.Builder>
      Throws:
      IOException
    • getMatchingLabelCase

      public DataPolicy.MatchingLabelCase getMatchingLabelCase()
      Specified by:
      getMatchingLabelCase in interface DataPolicyOrBuilder
    • clearMatchingLabel

      public DataPolicy.Builder clearMatchingLabel()
    • getPolicyCase

      public DataPolicy.PolicyCase getPolicyCase()
      Specified by:
      getPolicyCase in interface DataPolicyOrBuilder
    • clearPolicy

      public DataPolicy.Builder clearPolicy()
    • hasPolicyTag

      public boolean hasPolicyTag()
       Policy tag resource name, in the format of
       `projects/{project_number}/locations/{location_id}/taxonomies/{taxonomy_id}/policyTags/{policyTag_id}`.
       
      string policy_tag = 4;
      Specified by:
      hasPolicyTag in interface DataPolicyOrBuilder
      Returns:
      Whether the policyTag field is set.
    • getPolicyTag

      public String getPolicyTag()
       Policy tag resource name, in the format of
       `projects/{project_number}/locations/{location_id}/taxonomies/{taxonomy_id}/policyTags/{policyTag_id}`.
       
      string policy_tag = 4;
      Specified by:
      getPolicyTag in interface DataPolicyOrBuilder
      Returns:
      The policyTag.
    • getPolicyTagBytes

      public com.google.protobuf.ByteString getPolicyTagBytes()
       Policy tag resource name, in the format of
       `projects/{project_number}/locations/{location_id}/taxonomies/{taxonomy_id}/policyTags/{policyTag_id}`.
       
      string policy_tag = 4;
      Specified by:
      getPolicyTagBytes in interface DataPolicyOrBuilder
      Returns:
      The bytes for policyTag.
    • setPolicyTag

      public DataPolicy.Builder setPolicyTag(String value)
       Policy tag resource name, in the format of
       `projects/{project_number}/locations/{location_id}/taxonomies/{taxonomy_id}/policyTags/{policyTag_id}`.
       
      string policy_tag = 4;
      Parameters:
      value - The policyTag to set.
      Returns:
      This builder for chaining.
    • clearPolicyTag

      public DataPolicy.Builder clearPolicyTag()
       Policy tag resource name, in the format of
       `projects/{project_number}/locations/{location_id}/taxonomies/{taxonomy_id}/policyTags/{policyTag_id}`.
       
      string policy_tag = 4;
      Returns:
      This builder for chaining.
    • setPolicyTagBytes

      public DataPolicy.Builder setPolicyTagBytes(com.google.protobuf.ByteString value)
       Policy tag resource name, in the format of
       `projects/{project_number}/locations/{location_id}/taxonomies/{taxonomy_id}/policyTags/{policyTag_id}`.
       
      string policy_tag = 4;
      Parameters:
      value - The bytes for policyTag to set.
      Returns:
      This builder for chaining.
    • hasDataMaskingPolicy

      public boolean hasDataMaskingPolicy()
       The data masking policy that specifies the data masking rule to use.
       
      .google.cloud.bigquery.datapolicies.v1.DataMaskingPolicy data_masking_policy = 5;
      Specified by:
      hasDataMaskingPolicy in interface DataPolicyOrBuilder
      Returns:
      Whether the dataMaskingPolicy field is set.
    • getDataMaskingPolicy

      public DataMaskingPolicy getDataMaskingPolicy()
       The data masking policy that specifies the data masking rule to use.
       
      .google.cloud.bigquery.datapolicies.v1.DataMaskingPolicy data_masking_policy = 5;
      Specified by:
      getDataMaskingPolicy in interface DataPolicyOrBuilder
      Returns:
      The dataMaskingPolicy.
    • setDataMaskingPolicy

      public DataPolicy.Builder setDataMaskingPolicy(DataMaskingPolicy value)
       The data masking policy that specifies the data masking rule to use.
       
      .google.cloud.bigquery.datapolicies.v1.DataMaskingPolicy data_masking_policy = 5;
    • setDataMaskingPolicy

      public DataPolicy.Builder setDataMaskingPolicy(DataMaskingPolicy.Builder builderForValue)
       The data masking policy that specifies the data masking rule to use.
       
      .google.cloud.bigquery.datapolicies.v1.DataMaskingPolicy data_masking_policy = 5;
    • mergeDataMaskingPolicy

      public DataPolicy.Builder mergeDataMaskingPolicy(DataMaskingPolicy value)
       The data masking policy that specifies the data masking rule to use.
       
      .google.cloud.bigquery.datapolicies.v1.DataMaskingPolicy data_masking_policy = 5;
    • clearDataMaskingPolicy

      public DataPolicy.Builder clearDataMaskingPolicy()
       The data masking policy that specifies the data masking rule to use.
       
      .google.cloud.bigquery.datapolicies.v1.DataMaskingPolicy data_masking_policy = 5;
    • getDataMaskingPolicyBuilder

      public DataMaskingPolicy.Builder getDataMaskingPolicyBuilder()
       The data masking policy that specifies the data masking rule to use.
       
      .google.cloud.bigquery.datapolicies.v1.DataMaskingPolicy data_masking_policy = 5;
    • getDataMaskingPolicyOrBuilder

      public DataMaskingPolicyOrBuilder getDataMaskingPolicyOrBuilder()
       The data masking policy that specifies the data masking rule to use.
       
      .google.cloud.bigquery.datapolicies.v1.DataMaskingPolicy data_masking_policy = 5;
      Specified by:
      getDataMaskingPolicyOrBuilder in interface DataPolicyOrBuilder
    • getName

      public String getName()
       Output only. Resource name of this data policy, in the format of
       `projects/{project_number}/locations/{location_id}/dataPolicies/{data_policy_id}`.
       
      string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY];
      Specified by:
      getName in interface DataPolicyOrBuilder
      Returns:
      The name.
    • getNameBytes

      public com.google.protobuf.ByteString getNameBytes()
       Output only. Resource name of this data policy, in the format of
       `projects/{project_number}/locations/{location_id}/dataPolicies/{data_policy_id}`.
       
      string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY];
      Specified by:
      getNameBytes in interface DataPolicyOrBuilder
      Returns:
      The bytes for name.
    • setName

      public DataPolicy.Builder setName(String value)
       Output only. Resource name of this data policy, in the format of
       `projects/{project_number}/locations/{location_id}/dataPolicies/{data_policy_id}`.
       
      string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY];
      Parameters:
      value - The name to set.
      Returns:
      This builder for chaining.
    • clearName

      public DataPolicy.Builder clearName()
       Output only. Resource name of this data policy, in the format of
       `projects/{project_number}/locations/{location_id}/dataPolicies/{data_policy_id}`.
       
      string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY];
      Returns:
      This builder for chaining.
    • setNameBytes

      public DataPolicy.Builder setNameBytes(com.google.protobuf.ByteString value)
       Output only. Resource name of this data policy, in the format of
       `projects/{project_number}/locations/{location_id}/dataPolicies/{data_policy_id}`.
       
      string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY];
      Parameters:
      value - The bytes for name to set.
      Returns:
      This builder for chaining.
    • getDataPolicyTypeValue

      public int getDataPolicyTypeValue()
       Type of data policy.
       
      .google.cloud.bigquery.datapolicies.v1.DataPolicy.DataPolicyType data_policy_type = 2;
      Specified by:
      getDataPolicyTypeValue in interface DataPolicyOrBuilder
      Returns:
      The enum numeric value on the wire for dataPolicyType.
    • setDataPolicyTypeValue

      public DataPolicy.Builder setDataPolicyTypeValue(int value)
       Type of data policy.
       
      .google.cloud.bigquery.datapolicies.v1.DataPolicy.DataPolicyType data_policy_type = 2;
      Parameters:
      value - The enum numeric value on the wire for dataPolicyType to set.
      Returns:
      This builder for chaining.
    • getDataPolicyType

      public DataPolicy.DataPolicyType getDataPolicyType()
       Type of data policy.
       
      .google.cloud.bigquery.datapolicies.v1.DataPolicy.DataPolicyType data_policy_type = 2;
      Specified by:
      getDataPolicyType in interface DataPolicyOrBuilder
      Returns:
      The dataPolicyType.
    • setDataPolicyType

      public DataPolicy.Builder setDataPolicyType(DataPolicy.DataPolicyType value)
       Type of data policy.
       
      .google.cloud.bigquery.datapolicies.v1.DataPolicy.DataPolicyType data_policy_type = 2;
      Parameters:
      value - The dataPolicyType to set.
      Returns:
      This builder for chaining.
    • clearDataPolicyType

      public DataPolicy.Builder clearDataPolicyType()
       Type of data policy.
       
      .google.cloud.bigquery.datapolicies.v1.DataPolicy.DataPolicyType data_policy_type = 2;
      Returns:
      This builder for chaining.
    • getDataPolicyId

      public String getDataPolicyId()
       User-assigned (human readable) ID of the data policy that needs to be
       unique within a project. Used as {data_policy_id} in part of the resource
       name.
       
      string data_policy_id = 3;
      Specified by:
      getDataPolicyId in interface DataPolicyOrBuilder
      Returns:
      The dataPolicyId.
    • getDataPolicyIdBytes

      public com.google.protobuf.ByteString getDataPolicyIdBytes()
       User-assigned (human readable) ID of the data policy that needs to be
       unique within a project. Used as {data_policy_id} in part of the resource
       name.
       
      string data_policy_id = 3;
      Specified by:
      getDataPolicyIdBytes in interface DataPolicyOrBuilder
      Returns:
      The bytes for dataPolicyId.
    • setDataPolicyId

      public DataPolicy.Builder setDataPolicyId(String value)
       User-assigned (human readable) ID of the data policy that needs to be
       unique within a project. Used as {data_policy_id} in part of the resource
       name.
       
      string data_policy_id = 3;
      Parameters:
      value - The dataPolicyId to set.
      Returns:
      This builder for chaining.
    • clearDataPolicyId

      public DataPolicy.Builder clearDataPolicyId()
       User-assigned (human readable) ID of the data policy that needs to be
       unique within a project. Used as {data_policy_id} in part of the resource
       name.
       
      string data_policy_id = 3;
      Returns:
      This builder for chaining.
    • setDataPolicyIdBytes

      public DataPolicy.Builder setDataPolicyIdBytes(com.google.protobuf.ByteString value)
       User-assigned (human readable) ID of the data policy that needs to be
       unique within a project. Used as {data_policy_id} in part of the resource
       name.
       
      string data_policy_id = 3;
      Parameters:
      value - The bytes for dataPolicyId to set.
      Returns:
      This builder for chaining.