Class Distribution.Exemplar.Builder

java.lang.Object
com.google.protobuf.AbstractMessageLite.Builder
com.google.protobuf.AbstractMessage.Builder<BuilderType>
com.google.protobuf.GeneratedMessageV3.Builder<Distribution.Exemplar.Builder>
com.google.api.Distribution.Exemplar.Builder
All Implemented Interfaces:
Distribution.ExemplarOrBuilder, com.google.protobuf.Message.Builder, com.google.protobuf.MessageLite.Builder, com.google.protobuf.MessageLiteOrBuilder, com.google.protobuf.MessageOrBuilder, 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 Details

    • getDescriptor

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

      protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable()
      Specified by:
      internalGetFieldAccessorTable in class com.google.protobuf.GeneratedMessageV3.Builder<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.GeneratedMessageV3.Builder<Distribution.Exemplar.Builder>
    • getDefaultInstanceForType

      public Distribution.Exemplar getDefaultInstanceForType()
      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

      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, 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, 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, Object value)
      Specified by:
      addRepeatedField in interface com.google.protobuf.Message.Builder
      Overrides:
      addRepeatedField in class com.google.protobuf.GeneratedMessageV3.Builder<Distribution.Exemplar.Builder>
    • mergeFrom

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

    • isInitialized

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

      public Distribution.Exemplar.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<Distribution.Exemplar.Builder>
      Throws:
      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 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(Timestamp value)
       The observation (sampling) time of the above value.
       
      .google.protobuf.Timestamp timestamp = 2;
    • setTimestamp

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

      public Distribution.Exemplar.Builder mergeTimestamp(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 Timestamp.Builder getTimestampBuilder()
       The observation (sampling) time of the above value.
       
      .google.protobuf.Timestamp timestamp = 2;
    • getTimestampOrBuilder

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

      public List<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 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, 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, 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(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, 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(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, 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(Iterable<? extends 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 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 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 List<? extends 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 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 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 List<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>