Class Distribution.Exemplar.Builder

  • All Implemented Interfaces:
    Distribution.ExemplarOrBuilder, 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:
    Distribution.Exemplar

    public static final class Distribution.Exemplar.Builder
    extends com.google.protobuf.GeneratedMessageV3.Builder<Distribution.Exemplar.Builder>
    implements Distribution.ExemplarOrBuilder
     Exemplars are example points that may be used to annotate aggregated
     distribution values. They are metadata that gives information about a
     particular value added to a Distribution bucket, such as a trace ID that
     was active when a value was added. They may contain further information,
     such as a example values and timestamps, origin, etc.
     
    Protobuf type google.api.Distribution.Exemplar
    • 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<Distribution.Exemplar.Builder>
      • clear

        public Distribution.Exemplar.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.GeneratedMessageV3.Builder<Distribution.Exemplar.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<Distribution.Exemplar.Builder>
      • getDefaultInstanceForType

        public Distribution.Exemplar 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 Distribution.Exemplar build()
        Specified by:
        build in interface com.google.protobuf.Message.Builder
        Specified by:
        build in interface com.google.protobuf.MessageLite.Builder
      • buildPartial

        public Distribution.Exemplar buildPartial()
        Specified by:
        buildPartial in interface com.google.protobuf.Message.Builder
        Specified by:
        buildPartial in interface com.google.protobuf.MessageLite.Builder
      • clone

        public Distribution.Exemplar.Builder clone()
        Specified by:
        clone in interface com.google.protobuf.Message.Builder
        Specified by:
        clone in interface com.google.protobuf.MessageLite.Builder
        Overrides:
        clone in class com.google.protobuf.GeneratedMessageV3.Builder<Distribution.Exemplar.Builder>
      • setField

        public Distribution.Exemplar.Builder setField​(com.google.protobuf.Descriptors.FieldDescriptor field,
                                                      java.lang.Object value)
        Specified by:
        setField in interface com.google.protobuf.Message.Builder
        Overrides:
        setField in class com.google.protobuf.GeneratedMessageV3.Builder<Distribution.Exemplar.Builder>
      • clearField

        public Distribution.Exemplar.Builder clearField​(com.google.protobuf.Descriptors.FieldDescriptor field)
        Specified by:
        clearField in interface com.google.protobuf.Message.Builder
        Overrides:
        clearField in class com.google.protobuf.GeneratedMessageV3.Builder<Distribution.Exemplar.Builder>
      • clearOneof

        public Distribution.Exemplar.Builder clearOneof​(com.google.protobuf.Descriptors.OneofDescriptor oneof)
        Specified by:
        clearOneof in interface com.google.protobuf.Message.Builder
        Overrides:
        clearOneof in class com.google.protobuf.GeneratedMessageV3.Builder<Distribution.Exemplar.Builder>
      • setRepeatedField

        public Distribution.Exemplar.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<Distribution.Exemplar.Builder>
      • addRepeatedField

        public Distribution.Exemplar.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<Distribution.Exemplar.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,​Distribution.Exemplar.Builder>
      • mergeFrom

        public Distribution.Exemplar.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<Distribution.Exemplar.Builder>
        Throws:
        java.io.IOException
      • getValue

        public double getValue()
         Value of the exemplar point. This value determines to which bucket the
         exemplar belongs.
         
        double value = 1;
        Specified by:
        getValue in interface Distribution.ExemplarOrBuilder
        Returns:
        The value.
      • setValue

        public Distribution.Exemplar.Builder setValue​(double value)
         Value of the exemplar point. This value determines to which bucket the
         exemplar belongs.
         
        double value = 1;
        Parameters:
        value - The value to set.
        Returns:
        This builder for chaining.
      • clearValue

        public Distribution.Exemplar.Builder clearValue()
         Value of the exemplar point. This value determines to which bucket the
         exemplar belongs.
         
        double value = 1;
        Returns:
        This builder for chaining.
      • hasTimestamp

        public boolean hasTimestamp()
         The observation (sampling) time of the above value.
         
        .google.protobuf.Timestamp timestamp = 2;
        Specified by:
        hasTimestamp in interface Distribution.ExemplarOrBuilder
        Returns:
        Whether the timestamp field is set.
      • getTimestamp

        public com.google.protobuf.Timestamp getTimestamp()
         The observation (sampling) time of the above value.
         
        .google.protobuf.Timestamp timestamp = 2;
        Specified by:
        getTimestamp in interface Distribution.ExemplarOrBuilder
        Returns:
        The timestamp.
      • setTimestamp

        public Distribution.Exemplar.Builder setTimestamp​(com.google.protobuf.Timestamp value)
         The observation (sampling) time of the above value.
         
        .google.protobuf.Timestamp timestamp = 2;
      • setTimestamp

        public Distribution.Exemplar.Builder setTimestamp​(com.google.protobuf.Timestamp.Builder builderForValue)
         The observation (sampling) time of the above value.
         
        .google.protobuf.Timestamp timestamp = 2;
      • mergeTimestamp

        public Distribution.Exemplar.Builder mergeTimestamp​(com.google.protobuf.Timestamp value)
         The observation (sampling) time of the above value.
         
        .google.protobuf.Timestamp timestamp = 2;
      • clearTimestamp

        public Distribution.Exemplar.Builder clearTimestamp()
         The observation (sampling) time of the above value.
         
        .google.protobuf.Timestamp timestamp = 2;
      • getTimestampBuilder

        public com.google.protobuf.Timestamp.Builder getTimestampBuilder()
         The observation (sampling) time of the above value.
         
        .google.protobuf.Timestamp timestamp = 2;
      • getTimestampOrBuilder

        public com.google.protobuf.TimestampOrBuilder getTimestampOrBuilder()
         The observation (sampling) time of the above value.
         
        .google.protobuf.Timestamp timestamp = 2;
        Specified by:
        getTimestampOrBuilder in interface Distribution.ExemplarOrBuilder
      • getAttachmentsList

        public java.util.List<com.google.protobuf.Any> getAttachmentsList()
         Contextual information about the example value. Examples are:
        
           Trace: type.googleapis.com/google.monitoring.v3.SpanContext
        
           Literal string: type.googleapis.com/google.protobuf.StringValue
        
           Labels dropped during aggregation:
             type.googleapis.com/google.monitoring.v3.DroppedLabels
        
         There may be only a single attachment of any given message type in a
         single exemplar, and this is enforced by the system.
         
        repeated .google.protobuf.Any attachments = 3;
        Specified by:
        getAttachmentsList in interface Distribution.ExemplarOrBuilder
      • getAttachmentsCount

        public int getAttachmentsCount()
         Contextual information about the example value. Examples are:
        
           Trace: type.googleapis.com/google.monitoring.v3.SpanContext
        
           Literal string: type.googleapis.com/google.protobuf.StringValue
        
           Labels dropped during aggregation:
             type.googleapis.com/google.monitoring.v3.DroppedLabels
        
         There may be only a single attachment of any given message type in a
         single exemplar, and this is enforced by the system.
         
        repeated .google.protobuf.Any attachments = 3;
        Specified by:
        getAttachmentsCount in interface Distribution.ExemplarOrBuilder
      • getAttachments

        public com.google.protobuf.Any getAttachments​(int index)
         Contextual information about the example value. Examples are:
        
           Trace: type.googleapis.com/google.monitoring.v3.SpanContext
        
           Literal string: type.googleapis.com/google.protobuf.StringValue
        
           Labels dropped during aggregation:
             type.googleapis.com/google.monitoring.v3.DroppedLabels
        
         There may be only a single attachment of any given message type in a
         single exemplar, and this is enforced by the system.
         
        repeated .google.protobuf.Any attachments = 3;
        Specified by:
        getAttachments in interface Distribution.ExemplarOrBuilder
      • setAttachments

        public Distribution.Exemplar.Builder setAttachments​(int index,
                                                            com.google.protobuf.Any value)
         Contextual information about the example value. Examples are:
        
           Trace: type.googleapis.com/google.monitoring.v3.SpanContext
        
           Literal string: type.googleapis.com/google.protobuf.StringValue
        
           Labels dropped during aggregation:
             type.googleapis.com/google.monitoring.v3.DroppedLabels
        
         There may be only a single attachment of any given message type in a
         single exemplar, and this is enforced by the system.
         
        repeated .google.protobuf.Any attachments = 3;
      • setAttachments

        public Distribution.Exemplar.Builder setAttachments​(int index,
                                                            com.google.protobuf.Any.Builder builderForValue)
         Contextual information about the example value. Examples are:
        
           Trace: type.googleapis.com/google.monitoring.v3.SpanContext
        
           Literal string: type.googleapis.com/google.protobuf.StringValue
        
           Labels dropped during aggregation:
             type.googleapis.com/google.monitoring.v3.DroppedLabels
        
         There may be only a single attachment of any given message type in a
         single exemplar, and this is enforced by the system.
         
        repeated .google.protobuf.Any attachments = 3;
      • addAttachments

        public Distribution.Exemplar.Builder addAttachments​(com.google.protobuf.Any value)
         Contextual information about the example value. Examples are:
        
           Trace: type.googleapis.com/google.monitoring.v3.SpanContext
        
           Literal string: type.googleapis.com/google.protobuf.StringValue
        
           Labels dropped during aggregation:
             type.googleapis.com/google.monitoring.v3.DroppedLabels
        
         There may be only a single attachment of any given message type in a
         single exemplar, and this is enforced by the system.
         
        repeated .google.protobuf.Any attachments = 3;
      • addAttachments

        public Distribution.Exemplar.Builder addAttachments​(int index,
                                                            com.google.protobuf.Any value)
         Contextual information about the example value. Examples are:
        
           Trace: type.googleapis.com/google.monitoring.v3.SpanContext
        
           Literal string: type.googleapis.com/google.protobuf.StringValue
        
           Labels dropped during aggregation:
             type.googleapis.com/google.monitoring.v3.DroppedLabels
        
         There may be only a single attachment of any given message type in a
         single exemplar, and this is enforced by the system.
         
        repeated .google.protobuf.Any attachments = 3;
      • addAttachments

        public Distribution.Exemplar.Builder addAttachments​(com.google.protobuf.Any.Builder builderForValue)
         Contextual information about the example value. Examples are:
        
           Trace: type.googleapis.com/google.monitoring.v3.SpanContext
        
           Literal string: type.googleapis.com/google.protobuf.StringValue
        
           Labels dropped during aggregation:
             type.googleapis.com/google.monitoring.v3.DroppedLabels
        
         There may be only a single attachment of any given message type in a
         single exemplar, and this is enforced by the system.
         
        repeated .google.protobuf.Any attachments = 3;
      • addAttachments

        public Distribution.Exemplar.Builder addAttachments​(int index,
                                                            com.google.protobuf.Any.Builder builderForValue)
         Contextual information about the example value. Examples are:
        
           Trace: type.googleapis.com/google.monitoring.v3.SpanContext
        
           Literal string: type.googleapis.com/google.protobuf.StringValue
        
           Labels dropped during aggregation:
             type.googleapis.com/google.monitoring.v3.DroppedLabels
        
         There may be only a single attachment of any given message type in a
         single exemplar, and this is enforced by the system.
         
        repeated .google.protobuf.Any attachments = 3;
      • addAllAttachments

        public Distribution.Exemplar.Builder addAllAttachments​(java.lang.Iterable<? extends com.google.protobuf.Any> values)
         Contextual information about the example value. Examples are:
        
           Trace: type.googleapis.com/google.monitoring.v3.SpanContext
        
           Literal string: type.googleapis.com/google.protobuf.StringValue
        
           Labels dropped during aggregation:
             type.googleapis.com/google.monitoring.v3.DroppedLabels
        
         There may be only a single attachment of any given message type in a
         single exemplar, and this is enforced by the system.
         
        repeated .google.protobuf.Any attachments = 3;
      • clearAttachments

        public Distribution.Exemplar.Builder clearAttachments()
         Contextual information about the example value. Examples are:
        
           Trace: type.googleapis.com/google.monitoring.v3.SpanContext
        
           Literal string: type.googleapis.com/google.protobuf.StringValue
        
           Labels dropped during aggregation:
             type.googleapis.com/google.monitoring.v3.DroppedLabels
        
         There may be only a single attachment of any given message type in a
         single exemplar, and this is enforced by the system.
         
        repeated .google.protobuf.Any attachments = 3;
      • removeAttachments

        public Distribution.Exemplar.Builder removeAttachments​(int index)
         Contextual information about the example value. Examples are:
        
           Trace: type.googleapis.com/google.monitoring.v3.SpanContext
        
           Literal string: type.googleapis.com/google.protobuf.StringValue
        
           Labels dropped during aggregation:
             type.googleapis.com/google.monitoring.v3.DroppedLabels
        
         There may be only a single attachment of any given message type in a
         single exemplar, and this is enforced by the system.
         
        repeated .google.protobuf.Any attachments = 3;
      • getAttachmentsBuilder

        public com.google.protobuf.Any.Builder getAttachmentsBuilder​(int index)
         Contextual information about the example value. Examples are:
        
           Trace: type.googleapis.com/google.monitoring.v3.SpanContext
        
           Literal string: type.googleapis.com/google.protobuf.StringValue
        
           Labels dropped during aggregation:
             type.googleapis.com/google.monitoring.v3.DroppedLabels
        
         There may be only a single attachment of any given message type in a
         single exemplar, and this is enforced by the system.
         
        repeated .google.protobuf.Any attachments = 3;
      • getAttachmentsOrBuilder

        public com.google.protobuf.AnyOrBuilder getAttachmentsOrBuilder​(int index)
         Contextual information about the example value. Examples are:
        
           Trace: type.googleapis.com/google.monitoring.v3.SpanContext
        
           Literal string: type.googleapis.com/google.protobuf.StringValue
        
           Labels dropped during aggregation:
             type.googleapis.com/google.monitoring.v3.DroppedLabels
        
         There may be only a single attachment of any given message type in a
         single exemplar, and this is enforced by the system.
         
        repeated .google.protobuf.Any attachments = 3;
        Specified by:
        getAttachmentsOrBuilder in interface Distribution.ExemplarOrBuilder
      • getAttachmentsOrBuilderList

        public java.util.List<? extends com.google.protobuf.AnyOrBuilder> getAttachmentsOrBuilderList()
         Contextual information about the example value. Examples are:
        
           Trace: type.googleapis.com/google.monitoring.v3.SpanContext
        
           Literal string: type.googleapis.com/google.protobuf.StringValue
        
           Labels dropped during aggregation:
             type.googleapis.com/google.monitoring.v3.DroppedLabels
        
         There may be only a single attachment of any given message type in a
         single exemplar, and this is enforced by the system.
         
        repeated .google.protobuf.Any attachments = 3;
        Specified by:
        getAttachmentsOrBuilderList in interface Distribution.ExemplarOrBuilder
      • addAttachmentsBuilder

        public com.google.protobuf.Any.Builder addAttachmentsBuilder()
         Contextual information about the example value. Examples are:
        
           Trace: type.googleapis.com/google.monitoring.v3.SpanContext
        
           Literal string: type.googleapis.com/google.protobuf.StringValue
        
           Labels dropped during aggregation:
             type.googleapis.com/google.monitoring.v3.DroppedLabels
        
         There may be only a single attachment of any given message type in a
         single exemplar, and this is enforced by the system.
         
        repeated .google.protobuf.Any attachments = 3;
      • addAttachmentsBuilder

        public com.google.protobuf.Any.Builder addAttachmentsBuilder​(int index)
         Contextual information about the example value. Examples are:
        
           Trace: type.googleapis.com/google.monitoring.v3.SpanContext
        
           Literal string: type.googleapis.com/google.protobuf.StringValue
        
           Labels dropped during aggregation:
             type.googleapis.com/google.monitoring.v3.DroppedLabels
        
         There may be only a single attachment of any given message type in a
         single exemplar, and this is enforced by the system.
         
        repeated .google.protobuf.Any attachments = 3;
      • getAttachmentsBuilderList

        public java.util.List<com.google.protobuf.Any.Builder> getAttachmentsBuilderList()
         Contextual information about the example value. Examples are:
        
           Trace: type.googleapis.com/google.monitoring.v3.SpanContext
        
           Literal string: type.googleapis.com/google.protobuf.StringValue
        
           Labels dropped during aggregation:
             type.googleapis.com/google.monitoring.v3.DroppedLabels
        
         There may be only a single attachment of any given message type in a
         single exemplar, and this is enforced by the system.
         
        repeated .google.protobuf.Any attachments = 3;
      • setUnknownFields

        public final Distribution.Exemplar.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<Distribution.Exemplar.Builder>
      • mergeUnknownFields

        public final Distribution.Exemplar.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<Distribution.Exemplar.Builder>