Class ConsumerQuotaLimit.Builder

java.lang.Object
com.google.protobuf.AbstractMessageLite.Builder
com.google.protobuf.AbstractMessage.Builder<BuilderT>
com.google.protobuf.GeneratedMessage.Builder<ConsumerQuotaLimit.Builder>
com.google.api.serviceusage.v1beta1.ConsumerQuotaLimit.Builder
All Implemented Interfaces:
ConsumerQuotaLimitOrBuilder, com.google.protobuf.Message.Builder, com.google.protobuf.MessageLite.Builder, com.google.protobuf.MessageLiteOrBuilder, com.google.protobuf.MessageOrBuilder, Cloneable
Enclosing class:
ConsumerQuotaLimit

public static final class ConsumerQuotaLimit.Builder extends com.google.protobuf.GeneratedMessage.Builder<ConsumerQuotaLimit.Builder> implements ConsumerQuotaLimitOrBuilder
 Consumer quota settings for a quota limit.
 
Protobuf type google.api.serviceusage.v1beta1.ConsumerQuotaLimit
  • 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<ConsumerQuotaLimit.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<ConsumerQuotaLimit.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<ConsumerQuotaLimit.Builder>
    • getDefaultInstanceForType

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

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

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

      public ConsumerQuotaLimit.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<ConsumerQuotaLimit.Builder>
    • mergeFrom

    • isInitialized

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

      public ConsumerQuotaLimit.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<ConsumerQuotaLimit.Builder>
      Throws:
      IOException
    • getName

      public String getName()
       The resource name of the quota limit.
      
       An example name would be:
       `projects/123/services/compute.googleapis.com/consumerQuotaMetrics/compute.googleapis.com%2Fcpus/limits/%2Fproject%2Fregion`
      
       The resource name is intended to be opaque and should not be parsed for
       its component strings, since its representation could change in the future.
       
      string name = 1;
      Specified by:
      getName in interface ConsumerQuotaLimitOrBuilder
      Returns:
      The name.
    • getNameBytes

      public com.google.protobuf.ByteString getNameBytes()
       The resource name of the quota limit.
      
       An example name would be:
       `projects/123/services/compute.googleapis.com/consumerQuotaMetrics/compute.googleapis.com%2Fcpus/limits/%2Fproject%2Fregion`
      
       The resource name is intended to be opaque and should not be parsed for
       its component strings, since its representation could change in the future.
       
      string name = 1;
      Specified by:
      getNameBytes in interface ConsumerQuotaLimitOrBuilder
      Returns:
      The bytes for name.
    • setName

      public ConsumerQuotaLimit.Builder setName(String value)
       The resource name of the quota limit.
      
       An example name would be:
       `projects/123/services/compute.googleapis.com/consumerQuotaMetrics/compute.googleapis.com%2Fcpus/limits/%2Fproject%2Fregion`
      
       The resource name is intended to be opaque and should not be parsed for
       its component strings, since its representation could change in the future.
       
      string name = 1;
      Parameters:
      value - The name to set.
      Returns:
      This builder for chaining.
    • clearName

      public ConsumerQuotaLimit.Builder clearName()
       The resource name of the quota limit.
      
       An example name would be:
       `projects/123/services/compute.googleapis.com/consumerQuotaMetrics/compute.googleapis.com%2Fcpus/limits/%2Fproject%2Fregion`
      
       The resource name is intended to be opaque and should not be parsed for
       its component strings, since its representation could change in the future.
       
      string name = 1;
      Returns:
      This builder for chaining.
    • setNameBytes

      public ConsumerQuotaLimit.Builder setNameBytes(com.google.protobuf.ByteString value)
       The resource name of the quota limit.
      
       An example name would be:
       `projects/123/services/compute.googleapis.com/consumerQuotaMetrics/compute.googleapis.com%2Fcpus/limits/%2Fproject%2Fregion`
      
       The resource name is intended to be opaque and should not be parsed for
       its component strings, since its representation could change in the future.
       
      string name = 1;
      Parameters:
      value - The bytes for name to set.
      Returns:
      This builder for chaining.
    • getMetric

      public String getMetric()
       The name of the parent metric of this limit.
      
       An example name would be:
       `compute.googleapis.com/cpus`
       
      string metric = 8;
      Specified by:
      getMetric in interface ConsumerQuotaLimitOrBuilder
      Returns:
      The metric.
    • getMetricBytes

      public com.google.protobuf.ByteString getMetricBytes()
       The name of the parent metric of this limit.
      
       An example name would be:
       `compute.googleapis.com/cpus`
       
      string metric = 8;
      Specified by:
      getMetricBytes in interface ConsumerQuotaLimitOrBuilder
      Returns:
      The bytes for metric.
    • setMetric

      public ConsumerQuotaLimit.Builder setMetric(String value)
       The name of the parent metric of this limit.
      
       An example name would be:
       `compute.googleapis.com/cpus`
       
      string metric = 8;
      Parameters:
      value - The metric to set.
      Returns:
      This builder for chaining.
    • clearMetric

      public ConsumerQuotaLimit.Builder clearMetric()
       The name of the parent metric of this limit.
      
       An example name would be:
       `compute.googleapis.com/cpus`
       
      string metric = 8;
      Returns:
      This builder for chaining.
    • setMetricBytes

      public ConsumerQuotaLimit.Builder setMetricBytes(com.google.protobuf.ByteString value)
       The name of the parent metric of this limit.
      
       An example name would be:
       `compute.googleapis.com/cpus`
       
      string metric = 8;
      Parameters:
      value - The bytes for metric to set.
      Returns:
      This builder for chaining.
    • getUnit

      public String getUnit()
       The limit unit.
      
       An example unit would be
       `1/{project}/{region}`
       Note that `{project}` and `{region}` are not placeholders in this example;
       the literal characters `{` and `}` occur in the string.
       
      string unit = 2;
      Specified by:
      getUnit in interface ConsumerQuotaLimitOrBuilder
      Returns:
      The unit.
    • getUnitBytes

      public com.google.protobuf.ByteString getUnitBytes()
       The limit unit.
      
       An example unit would be
       `1/{project}/{region}`
       Note that `{project}` and `{region}` are not placeholders in this example;
       the literal characters `{` and `}` occur in the string.
       
      string unit = 2;
      Specified by:
      getUnitBytes in interface ConsumerQuotaLimitOrBuilder
      Returns:
      The bytes for unit.
    • setUnit

      public ConsumerQuotaLimit.Builder setUnit(String value)
       The limit unit.
      
       An example unit would be
       `1/{project}/{region}`
       Note that `{project}` and `{region}` are not placeholders in this example;
       the literal characters `{` and `}` occur in the string.
       
      string unit = 2;
      Parameters:
      value - The unit to set.
      Returns:
      This builder for chaining.
    • clearUnit

      public ConsumerQuotaLimit.Builder clearUnit()
       The limit unit.
      
       An example unit would be
       `1/{project}/{region}`
       Note that `{project}` and `{region}` are not placeholders in this example;
       the literal characters `{` and `}` occur in the string.
       
      string unit = 2;
      Returns:
      This builder for chaining.
    • setUnitBytes

      public ConsumerQuotaLimit.Builder setUnitBytes(com.google.protobuf.ByteString value)
       The limit unit.
      
       An example unit would be
       `1/{project}/{region}`
       Note that `{project}` and `{region}` are not placeholders in this example;
       the literal characters `{` and `}` occur in the string.
       
      string unit = 2;
      Parameters:
      value - The bytes for unit to set.
      Returns:
      This builder for chaining.
    • getIsPrecise

      public boolean getIsPrecise()
       Whether this limit is precise or imprecise.
       
      bool is_precise = 3;
      Specified by:
      getIsPrecise in interface ConsumerQuotaLimitOrBuilder
      Returns:
      The isPrecise.
    • setIsPrecise

      public ConsumerQuotaLimit.Builder setIsPrecise(boolean value)
       Whether this limit is precise or imprecise.
       
      bool is_precise = 3;
      Parameters:
      value - The isPrecise to set.
      Returns:
      This builder for chaining.
    • clearIsPrecise

      public ConsumerQuotaLimit.Builder clearIsPrecise()
       Whether this limit is precise or imprecise.
       
      bool is_precise = 3;
      Returns:
      This builder for chaining.
    • getAllowsAdminOverrides

      public boolean getAllowsAdminOverrides()
       Whether admin overrides are allowed on this limit
       
      bool allows_admin_overrides = 7;
      Specified by:
      getAllowsAdminOverrides in interface ConsumerQuotaLimitOrBuilder
      Returns:
      The allowsAdminOverrides.
    • setAllowsAdminOverrides

      public ConsumerQuotaLimit.Builder setAllowsAdminOverrides(boolean value)
       Whether admin overrides are allowed on this limit
       
      bool allows_admin_overrides = 7;
      Parameters:
      value - The allowsAdminOverrides to set.
      Returns:
      This builder for chaining.
    • clearAllowsAdminOverrides

      public ConsumerQuotaLimit.Builder clearAllowsAdminOverrides()
       Whether admin overrides are allowed on this limit
       
      bool allows_admin_overrides = 7;
      Returns:
      This builder for chaining.
    • getQuotaBucketsList

      public List<QuotaBucket> getQuotaBucketsList()
       Summary of the enforced quota buckets, organized by quota dimension,
       ordered from least specific to most specific (for example, the global
       default bucket, with no quota dimensions, will always appear first).
       
      repeated .google.api.serviceusage.v1beta1.QuotaBucket quota_buckets = 9;
      Specified by:
      getQuotaBucketsList in interface ConsumerQuotaLimitOrBuilder
    • getQuotaBucketsCount

      public int getQuotaBucketsCount()
       Summary of the enforced quota buckets, organized by quota dimension,
       ordered from least specific to most specific (for example, the global
       default bucket, with no quota dimensions, will always appear first).
       
      repeated .google.api.serviceusage.v1beta1.QuotaBucket quota_buckets = 9;
      Specified by:
      getQuotaBucketsCount in interface ConsumerQuotaLimitOrBuilder
    • getQuotaBuckets

      public QuotaBucket getQuotaBuckets(int index)
       Summary of the enforced quota buckets, organized by quota dimension,
       ordered from least specific to most specific (for example, the global
       default bucket, with no quota dimensions, will always appear first).
       
      repeated .google.api.serviceusage.v1beta1.QuotaBucket quota_buckets = 9;
      Specified by:
      getQuotaBuckets in interface ConsumerQuotaLimitOrBuilder
    • setQuotaBuckets

      public ConsumerQuotaLimit.Builder setQuotaBuckets(int index, QuotaBucket value)
       Summary of the enforced quota buckets, organized by quota dimension,
       ordered from least specific to most specific (for example, the global
       default bucket, with no quota dimensions, will always appear first).
       
      repeated .google.api.serviceusage.v1beta1.QuotaBucket quota_buckets = 9;
    • setQuotaBuckets

      public ConsumerQuotaLimit.Builder setQuotaBuckets(int index, QuotaBucket.Builder builderForValue)
       Summary of the enforced quota buckets, organized by quota dimension,
       ordered from least specific to most specific (for example, the global
       default bucket, with no quota dimensions, will always appear first).
       
      repeated .google.api.serviceusage.v1beta1.QuotaBucket quota_buckets = 9;
    • addQuotaBuckets

      public ConsumerQuotaLimit.Builder addQuotaBuckets(QuotaBucket value)
       Summary of the enforced quota buckets, organized by quota dimension,
       ordered from least specific to most specific (for example, the global
       default bucket, with no quota dimensions, will always appear first).
       
      repeated .google.api.serviceusage.v1beta1.QuotaBucket quota_buckets = 9;
    • addQuotaBuckets

      public ConsumerQuotaLimit.Builder addQuotaBuckets(int index, QuotaBucket value)
       Summary of the enforced quota buckets, organized by quota dimension,
       ordered from least specific to most specific (for example, the global
       default bucket, with no quota dimensions, will always appear first).
       
      repeated .google.api.serviceusage.v1beta1.QuotaBucket quota_buckets = 9;
    • addQuotaBuckets

      public ConsumerQuotaLimit.Builder addQuotaBuckets(QuotaBucket.Builder builderForValue)
       Summary of the enforced quota buckets, organized by quota dimension,
       ordered from least specific to most specific (for example, the global
       default bucket, with no quota dimensions, will always appear first).
       
      repeated .google.api.serviceusage.v1beta1.QuotaBucket quota_buckets = 9;
    • addQuotaBuckets

      public ConsumerQuotaLimit.Builder addQuotaBuckets(int index, QuotaBucket.Builder builderForValue)
       Summary of the enforced quota buckets, organized by quota dimension,
       ordered from least specific to most specific (for example, the global
       default bucket, with no quota dimensions, will always appear first).
       
      repeated .google.api.serviceusage.v1beta1.QuotaBucket quota_buckets = 9;
    • addAllQuotaBuckets

      public ConsumerQuotaLimit.Builder addAllQuotaBuckets(Iterable<? extends QuotaBucket> values)
       Summary of the enforced quota buckets, organized by quota dimension,
       ordered from least specific to most specific (for example, the global
       default bucket, with no quota dimensions, will always appear first).
       
      repeated .google.api.serviceusage.v1beta1.QuotaBucket quota_buckets = 9;
    • clearQuotaBuckets

      public ConsumerQuotaLimit.Builder clearQuotaBuckets()
       Summary of the enforced quota buckets, organized by quota dimension,
       ordered from least specific to most specific (for example, the global
       default bucket, with no quota dimensions, will always appear first).
       
      repeated .google.api.serviceusage.v1beta1.QuotaBucket quota_buckets = 9;
    • removeQuotaBuckets

      public ConsumerQuotaLimit.Builder removeQuotaBuckets(int index)
       Summary of the enforced quota buckets, organized by quota dimension,
       ordered from least specific to most specific (for example, the global
       default bucket, with no quota dimensions, will always appear first).
       
      repeated .google.api.serviceusage.v1beta1.QuotaBucket quota_buckets = 9;
    • getQuotaBucketsBuilder

      public QuotaBucket.Builder getQuotaBucketsBuilder(int index)
       Summary of the enforced quota buckets, organized by quota dimension,
       ordered from least specific to most specific (for example, the global
       default bucket, with no quota dimensions, will always appear first).
       
      repeated .google.api.serviceusage.v1beta1.QuotaBucket quota_buckets = 9;
    • getQuotaBucketsOrBuilder

      public QuotaBucketOrBuilder getQuotaBucketsOrBuilder(int index)
       Summary of the enforced quota buckets, organized by quota dimension,
       ordered from least specific to most specific (for example, the global
       default bucket, with no quota dimensions, will always appear first).
       
      repeated .google.api.serviceusage.v1beta1.QuotaBucket quota_buckets = 9;
      Specified by:
      getQuotaBucketsOrBuilder in interface ConsumerQuotaLimitOrBuilder
    • getQuotaBucketsOrBuilderList

      public List<? extends QuotaBucketOrBuilder> getQuotaBucketsOrBuilderList()
       Summary of the enforced quota buckets, organized by quota dimension,
       ordered from least specific to most specific (for example, the global
       default bucket, with no quota dimensions, will always appear first).
       
      repeated .google.api.serviceusage.v1beta1.QuotaBucket quota_buckets = 9;
      Specified by:
      getQuotaBucketsOrBuilderList in interface ConsumerQuotaLimitOrBuilder
    • addQuotaBucketsBuilder

      public QuotaBucket.Builder addQuotaBucketsBuilder()
       Summary of the enforced quota buckets, organized by quota dimension,
       ordered from least specific to most specific (for example, the global
       default bucket, with no quota dimensions, will always appear first).
       
      repeated .google.api.serviceusage.v1beta1.QuotaBucket quota_buckets = 9;
    • addQuotaBucketsBuilder

      public QuotaBucket.Builder addQuotaBucketsBuilder(int index)
       Summary of the enforced quota buckets, organized by quota dimension,
       ordered from least specific to most specific (for example, the global
       default bucket, with no quota dimensions, will always appear first).
       
      repeated .google.api.serviceusage.v1beta1.QuotaBucket quota_buckets = 9;
    • getQuotaBucketsBuilderList

      public List<QuotaBucket.Builder> getQuotaBucketsBuilderList()
       Summary of the enforced quota buckets, organized by quota dimension,
       ordered from least specific to most specific (for example, the global
       default bucket, with no quota dimensions, will always appear first).
       
      repeated .google.api.serviceusage.v1beta1.QuotaBucket quota_buckets = 9;
    • getSupportedLocationsList

      public com.google.protobuf.ProtocolStringList getSupportedLocationsList()
       List of all supported locations.
       This field is present only if the limit has a {region} or {zone} dimension.
       
      repeated string supported_locations = 11;
      Specified by:
      getSupportedLocationsList in interface ConsumerQuotaLimitOrBuilder
      Returns:
      A list containing the supportedLocations.
    • getSupportedLocationsCount

      public int getSupportedLocationsCount()
       List of all supported locations.
       This field is present only if the limit has a {region} or {zone} dimension.
       
      repeated string supported_locations = 11;
      Specified by:
      getSupportedLocationsCount in interface ConsumerQuotaLimitOrBuilder
      Returns:
      The count of supportedLocations.
    • getSupportedLocations

      public String getSupportedLocations(int index)
       List of all supported locations.
       This field is present only if the limit has a {region} or {zone} dimension.
       
      repeated string supported_locations = 11;
      Specified by:
      getSupportedLocations in interface ConsumerQuotaLimitOrBuilder
      Parameters:
      index - The index of the element to return.
      Returns:
      The supportedLocations at the given index.
    • getSupportedLocationsBytes

      public com.google.protobuf.ByteString getSupportedLocationsBytes(int index)
       List of all supported locations.
       This field is present only if the limit has a {region} or {zone} dimension.
       
      repeated string supported_locations = 11;
      Specified by:
      getSupportedLocationsBytes in interface ConsumerQuotaLimitOrBuilder
      Parameters:
      index - The index of the value to return.
      Returns:
      The bytes of the supportedLocations at the given index.
    • setSupportedLocations

      public ConsumerQuotaLimit.Builder setSupportedLocations(int index, String value)
       List of all supported locations.
       This field is present only if the limit has a {region} or {zone} dimension.
       
      repeated string supported_locations = 11;
      Parameters:
      index - The index to set the value at.
      value - The supportedLocations to set.
      Returns:
      This builder for chaining.
    • addSupportedLocations

      public ConsumerQuotaLimit.Builder addSupportedLocations(String value)
       List of all supported locations.
       This field is present only if the limit has a {region} or {zone} dimension.
       
      repeated string supported_locations = 11;
      Parameters:
      value - The supportedLocations to add.
      Returns:
      This builder for chaining.
    • addAllSupportedLocations

      public ConsumerQuotaLimit.Builder addAllSupportedLocations(Iterable<String> values)
       List of all supported locations.
       This field is present only if the limit has a {region} or {zone} dimension.
       
      repeated string supported_locations = 11;
      Parameters:
      values - The supportedLocations to add.
      Returns:
      This builder for chaining.
    • clearSupportedLocations

      public ConsumerQuotaLimit.Builder clearSupportedLocations()
       List of all supported locations.
       This field is present only if the limit has a {region} or {zone} dimension.
       
      repeated string supported_locations = 11;
      Returns:
      This builder for chaining.
    • addSupportedLocationsBytes

      public ConsumerQuotaLimit.Builder addSupportedLocationsBytes(com.google.protobuf.ByteString value)
       List of all supported locations.
       This field is present only if the limit has a {region} or {zone} dimension.
       
      repeated string supported_locations = 11;
      Parameters:
      value - The bytes of the supportedLocations to add.
      Returns:
      This builder for chaining.