Class Billing.BillingDestination.Builder

  • All Implemented Interfaces:
    Billing.BillingDestinationOrBuilder, com.google.protobuf.GeneratedMessage.ExtendableMessageOrBuilder<com.google.protobuf.GeneratedMessageV3>, com.google.protobuf.Message.Builder, com.google.protobuf.MessageLite.Builder, com.google.protobuf.MessageLiteOrBuilder, com.google.protobuf.MessageOrBuilder, java.lang.Cloneable
    Enclosing class:
    Billing.BillingDestination

    public static final class Billing.BillingDestination.Builder
    extends com.google.protobuf.GeneratedMessageV3.Builder<Billing.BillingDestination.Builder>
    implements Billing.BillingDestinationOrBuilder
     Configuration of a specific billing destination (Currently only support
     bill against consumer project).
     
    Protobuf type google.api.Billing.BillingDestination
    • Method Detail

      • getDescriptor

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

        protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable()
        Overrides:
        internalGetFieldAccessorTable in class com.google.protobuf.GeneratedMessageV3.Builder<Billing.BillingDestination.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<Billing.BillingDestination.Builder>
      • getDefaultInstanceForType

        public Billing.BillingDestination getDefaultInstanceForType()
        Specified by:
        getDefaultInstanceForType in interface com.google.protobuf.GeneratedMessage.ExtendableMessageOrBuilder<com.google.protobuf.GeneratedMessageV3>
        Specified by:
        getDefaultInstanceForType in interface com.google.protobuf.MessageLiteOrBuilder
        Specified by:
        getDefaultInstanceForType in interface com.google.protobuf.MessageOrBuilder
      • build

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

        public Billing.BillingDestination buildPartial()
        Specified by:
        buildPartial in interface com.google.protobuf.Message.Builder
        Specified by:
        buildPartial in interface com.google.protobuf.MessageLite.Builder
      • setRepeatedField

        public Billing.BillingDestination.Builder setRepeatedField​(com.google.protobuf.Descriptors.FieldDescriptor field,
                                                                   int index,
                                                                   java.lang.Object value)
        Specified by:
        setRepeatedField in interface com.google.protobuf.Message.Builder
        Overrides:
        setRepeatedField in class com.google.protobuf.GeneratedMessageV3.Builder<Billing.BillingDestination.Builder>
      • addRepeatedField

        public Billing.BillingDestination.Builder addRepeatedField​(com.google.protobuf.Descriptors.FieldDescriptor field,
                                                                   java.lang.Object value)
        Specified by:
        addRepeatedField in interface com.google.protobuf.Message.Builder
        Overrides:
        addRepeatedField in class com.google.protobuf.GeneratedMessageV3.Builder<Billing.BillingDestination.Builder>
      • isInitialized

        public final boolean isInitialized()
        Specified by:
        isInitialized in interface com.google.protobuf.MessageLiteOrBuilder
        Overrides:
        isInitialized in class com.google.protobuf.GeneratedMessage.ExtendableBuilder<com.google.protobuf.GeneratedMessageV3,​Billing.BillingDestination.Builder>
      • mergeFrom

        public Billing.BillingDestination.Builder mergeFrom​(com.google.protobuf.CodedInputStream input,
                                                            com.google.protobuf.ExtensionRegistryLite extensionRegistry)
                                                     throws java.io.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<Billing.BillingDestination.Builder>
        Throws:
        java.io.IOException
      • getMonitoredResource

        public java.lang.String getMonitoredResource()
         The monitored resource type. The type must be defined in
         [Service.monitored_resources][google.api.Service.monitored_resources]
         section.
         
        string monitored_resource = 1;
        Specified by:
        getMonitoredResource in interface Billing.BillingDestinationOrBuilder
        Returns:
        The monitoredResource.
      • getMonitoredResourceBytes

        public com.google.protobuf.ByteString getMonitoredResourceBytes()
         The monitored resource type. The type must be defined in
         [Service.monitored_resources][google.api.Service.monitored_resources]
         section.
         
        string monitored_resource = 1;
        Specified by:
        getMonitoredResourceBytes in interface Billing.BillingDestinationOrBuilder
        Returns:
        The bytes for monitoredResource.
      • setMonitoredResource

        public Billing.BillingDestination.Builder setMonitoredResource​(java.lang.String value)
         The monitored resource type. The type must be defined in
         [Service.monitored_resources][google.api.Service.monitored_resources]
         section.
         
        string monitored_resource = 1;
        Parameters:
        value - The monitoredResource to set.
        Returns:
        This builder for chaining.
      • clearMonitoredResource

        public Billing.BillingDestination.Builder clearMonitoredResource()
         The monitored resource type. The type must be defined in
         [Service.monitored_resources][google.api.Service.monitored_resources]
         section.
         
        string monitored_resource = 1;
        Returns:
        This builder for chaining.
      • setMonitoredResourceBytes

        public Billing.BillingDestination.Builder setMonitoredResourceBytes​(com.google.protobuf.ByteString value)
         The monitored resource type. The type must be defined in
         [Service.monitored_resources][google.api.Service.monitored_resources]
         section.
         
        string monitored_resource = 1;
        Parameters:
        value - The bytes for monitoredResource to set.
        Returns:
        This builder for chaining.
      • getMetricsList

        public com.google.protobuf.ProtocolStringList getMetricsList()
         Names of the metrics to report to this billing destination.
         Each name must be defined in
         [Service.metrics][google.api.Service.metrics] section.
         
        repeated string metrics = 2;
        Specified by:
        getMetricsList in interface Billing.BillingDestinationOrBuilder
        Returns:
        A list containing the metrics.
      • getMetricsCount

        public int getMetricsCount()
         Names of the metrics to report to this billing destination.
         Each name must be defined in
         [Service.metrics][google.api.Service.metrics] section.
         
        repeated string metrics = 2;
        Specified by:
        getMetricsCount in interface Billing.BillingDestinationOrBuilder
        Returns:
        The count of metrics.
      • getMetrics

        public java.lang.String getMetrics​(int index)
         Names of the metrics to report to this billing destination.
         Each name must be defined in
         [Service.metrics][google.api.Service.metrics] section.
         
        repeated string metrics = 2;
        Specified by:
        getMetrics in interface Billing.BillingDestinationOrBuilder
        Parameters:
        index - The index of the element to return.
        Returns:
        The metrics at the given index.
      • getMetricsBytes

        public com.google.protobuf.ByteString getMetricsBytes​(int index)
         Names of the metrics to report to this billing destination.
         Each name must be defined in
         [Service.metrics][google.api.Service.metrics] section.
         
        repeated string metrics = 2;
        Specified by:
        getMetricsBytes in interface Billing.BillingDestinationOrBuilder
        Parameters:
        index - The index of the value to return.
        Returns:
        The bytes of the metrics at the given index.
      • setMetrics

        public Billing.BillingDestination.Builder setMetrics​(int index,
                                                             java.lang.String value)
         Names of the metrics to report to this billing destination.
         Each name must be defined in
         [Service.metrics][google.api.Service.metrics] section.
         
        repeated string metrics = 2;
        Parameters:
        index - The index to set the value at.
        value - The metrics to set.
        Returns:
        This builder for chaining.
      • addMetrics

        public Billing.BillingDestination.Builder addMetrics​(java.lang.String value)
         Names of the metrics to report to this billing destination.
         Each name must be defined in
         [Service.metrics][google.api.Service.metrics] section.
         
        repeated string metrics = 2;
        Parameters:
        value - The metrics to add.
        Returns:
        This builder for chaining.
      • addAllMetrics

        public Billing.BillingDestination.Builder addAllMetrics​(java.lang.Iterable<java.lang.String> values)
         Names of the metrics to report to this billing destination.
         Each name must be defined in
         [Service.metrics][google.api.Service.metrics] section.
         
        repeated string metrics = 2;
        Parameters:
        values - The metrics to add.
        Returns:
        This builder for chaining.
      • clearMetrics

        public Billing.BillingDestination.Builder clearMetrics()
         Names of the metrics to report to this billing destination.
         Each name must be defined in
         [Service.metrics][google.api.Service.metrics] section.
         
        repeated string metrics = 2;
        Returns:
        This builder for chaining.
      • addMetricsBytes

        public Billing.BillingDestination.Builder addMetricsBytes​(com.google.protobuf.ByteString value)
         Names of the metrics to report to this billing destination.
         Each name must be defined in
         [Service.metrics][google.api.Service.metrics] section.
         
        repeated string metrics = 2;
        Parameters:
        value - The bytes of the metrics to add.
        Returns:
        This builder for chaining.
      • setUnknownFields

        public final Billing.BillingDestination.Builder setUnknownFields​(com.google.protobuf.UnknownFieldSet unknownFields)
        Specified by:
        setUnknownFields in interface com.google.protobuf.Message.Builder
        Overrides:
        setUnknownFields in class com.google.protobuf.GeneratedMessageV3.Builder<Billing.BillingDestination.Builder>
      • mergeUnknownFields

        public final Billing.BillingDestination.Builder mergeUnknownFields​(com.google.protobuf.UnknownFieldSet unknownFields)
        Specified by:
        mergeUnknownFields in interface com.google.protobuf.Message.Builder
        Overrides:
        mergeUnknownFields in class com.google.protobuf.GeneratedMessageV3.Builder<Billing.BillingDestination.Builder>