Class ScopeSpans.Builder

java.lang.Object
com.google.protobuf.AbstractMessageLite.Builder
com.google.protobuf.AbstractMessage.Builder<BuilderT>
com.google.protobuf.GeneratedMessageV3.Builder<ScopeSpans.Builder>
io.opentelemetry.proto.trace.v1.ScopeSpans.Builder
All Implemented Interfaces:
com.google.protobuf.Message.Builder, com.google.protobuf.MessageLite.Builder, com.google.protobuf.MessageLiteOrBuilder, com.google.protobuf.MessageOrBuilder, ScopeSpansOrBuilder, Cloneable
Enclosing class:
ScopeSpans

public static final class ScopeSpans.Builder extends com.google.protobuf.GeneratedMessageV3.Builder<ScopeSpans.Builder> implements ScopeSpansOrBuilder
 A collection of Spans produced by an InstrumentationScope.
 
Protobuf type opentelemetry.proto.trace.v1.ScopeSpans
  • 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<ScopeSpans.Builder>
    • clear

      public ScopeSpans.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<ScopeSpans.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<ScopeSpans.Builder>
    • getDefaultInstanceForType

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

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

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

      public ScopeSpans.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<ScopeSpans.Builder>
    • setField

      public ScopeSpans.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<ScopeSpans.Builder>
    • clearField

      public ScopeSpans.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<ScopeSpans.Builder>
    • clearOneof

      public ScopeSpans.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<ScopeSpans.Builder>
    • setRepeatedField

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

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

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

      public ScopeSpans.Builder mergeFrom(ScopeSpans other)
    • isInitialized

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

      public ScopeSpans.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<ScopeSpans.Builder>
      Throws:
      IOException
    • hasScope

      public boolean hasScope()
       The instrumentation scope information for the spans in this message.
       Semantically when InstrumentationScope isn't set, it is equivalent with
       an empty instrumentation scope name (unknown).
       
      .opentelemetry.proto.common.v1.InstrumentationScope scope = 1;
      Specified by:
      hasScope in interface ScopeSpansOrBuilder
      Returns:
      Whether the scope field is set.
    • getScope

      public InstrumentationScope getScope()
       The instrumentation scope information for the spans in this message.
       Semantically when InstrumentationScope isn't set, it is equivalent with
       an empty instrumentation scope name (unknown).
       
      .opentelemetry.proto.common.v1.InstrumentationScope scope = 1;
      Specified by:
      getScope in interface ScopeSpansOrBuilder
      Returns:
      The scope.
    • setScope

      public ScopeSpans.Builder setScope(InstrumentationScope value)
       The instrumentation scope information for the spans in this message.
       Semantically when InstrumentationScope isn't set, it is equivalent with
       an empty instrumentation scope name (unknown).
       
      .opentelemetry.proto.common.v1.InstrumentationScope scope = 1;
    • setScope

      public ScopeSpans.Builder setScope(InstrumentationScope.Builder builderForValue)
       The instrumentation scope information for the spans in this message.
       Semantically when InstrumentationScope isn't set, it is equivalent with
       an empty instrumentation scope name (unknown).
       
      .opentelemetry.proto.common.v1.InstrumentationScope scope = 1;
    • mergeScope

      public ScopeSpans.Builder mergeScope(InstrumentationScope value)
       The instrumentation scope information for the spans in this message.
       Semantically when InstrumentationScope isn't set, it is equivalent with
       an empty instrumentation scope name (unknown).
       
      .opentelemetry.proto.common.v1.InstrumentationScope scope = 1;
    • clearScope

      public ScopeSpans.Builder clearScope()
       The instrumentation scope information for the spans in this message.
       Semantically when InstrumentationScope isn't set, it is equivalent with
       an empty instrumentation scope name (unknown).
       
      .opentelemetry.proto.common.v1.InstrumentationScope scope = 1;
    • getScopeBuilder

      public InstrumentationScope.Builder getScopeBuilder()
       The instrumentation scope information for the spans in this message.
       Semantically when InstrumentationScope isn't set, it is equivalent with
       an empty instrumentation scope name (unknown).
       
      .opentelemetry.proto.common.v1.InstrumentationScope scope = 1;
    • getScopeOrBuilder

      public InstrumentationScopeOrBuilder getScopeOrBuilder()
       The instrumentation scope information for the spans in this message.
       Semantically when InstrumentationScope isn't set, it is equivalent with
       an empty instrumentation scope name (unknown).
       
      .opentelemetry.proto.common.v1.InstrumentationScope scope = 1;
      Specified by:
      getScopeOrBuilder in interface ScopeSpansOrBuilder
    • getSpansList

      public List<Span> getSpansList()
       A list of Spans that originate from an instrumentation scope.
       
      repeated .opentelemetry.proto.trace.v1.Span spans = 2;
      Specified by:
      getSpansList in interface ScopeSpansOrBuilder
    • getSpansCount

      public int getSpansCount()
       A list of Spans that originate from an instrumentation scope.
       
      repeated .opentelemetry.proto.trace.v1.Span spans = 2;
      Specified by:
      getSpansCount in interface ScopeSpansOrBuilder
    • getSpans

      public Span getSpans(int index)
       A list of Spans that originate from an instrumentation scope.
       
      repeated .opentelemetry.proto.trace.v1.Span spans = 2;
      Specified by:
      getSpans in interface ScopeSpansOrBuilder
    • setSpans

      public ScopeSpans.Builder setSpans(int index, Span value)
       A list of Spans that originate from an instrumentation scope.
       
      repeated .opentelemetry.proto.trace.v1.Span spans = 2;
    • setSpans

      public ScopeSpans.Builder setSpans(int index, Span.Builder builderForValue)
       A list of Spans that originate from an instrumentation scope.
       
      repeated .opentelemetry.proto.trace.v1.Span spans = 2;
    • addSpans

      public ScopeSpans.Builder addSpans(Span value)
       A list of Spans that originate from an instrumentation scope.
       
      repeated .opentelemetry.proto.trace.v1.Span spans = 2;
    • addSpans

      public ScopeSpans.Builder addSpans(int index, Span value)
       A list of Spans that originate from an instrumentation scope.
       
      repeated .opentelemetry.proto.trace.v1.Span spans = 2;
    • addSpans

      public ScopeSpans.Builder addSpans(Span.Builder builderForValue)
       A list of Spans that originate from an instrumentation scope.
       
      repeated .opentelemetry.proto.trace.v1.Span spans = 2;
    • addSpans

      public ScopeSpans.Builder addSpans(int index, Span.Builder builderForValue)
       A list of Spans that originate from an instrumentation scope.
       
      repeated .opentelemetry.proto.trace.v1.Span spans = 2;
    • addAllSpans

      public ScopeSpans.Builder addAllSpans(Iterable<? extends Span> values)
       A list of Spans that originate from an instrumentation scope.
       
      repeated .opentelemetry.proto.trace.v1.Span spans = 2;
    • clearSpans

      public ScopeSpans.Builder clearSpans()
       A list of Spans that originate from an instrumentation scope.
       
      repeated .opentelemetry.proto.trace.v1.Span spans = 2;
    • removeSpans

      public ScopeSpans.Builder removeSpans(int index)
       A list of Spans that originate from an instrumentation scope.
       
      repeated .opentelemetry.proto.trace.v1.Span spans = 2;
    • getSpansBuilder

      public Span.Builder getSpansBuilder(int index)
       A list of Spans that originate from an instrumentation scope.
       
      repeated .opentelemetry.proto.trace.v1.Span spans = 2;
    • getSpansOrBuilder

      public SpanOrBuilder getSpansOrBuilder(int index)
       A list of Spans that originate from an instrumentation scope.
       
      repeated .opentelemetry.proto.trace.v1.Span spans = 2;
      Specified by:
      getSpansOrBuilder in interface ScopeSpansOrBuilder
    • getSpansOrBuilderList

      public List<? extends SpanOrBuilder> getSpansOrBuilderList()
       A list of Spans that originate from an instrumentation scope.
       
      repeated .opentelemetry.proto.trace.v1.Span spans = 2;
      Specified by:
      getSpansOrBuilderList in interface ScopeSpansOrBuilder
    • addSpansBuilder

      public Span.Builder addSpansBuilder()
       A list of Spans that originate from an instrumentation scope.
       
      repeated .opentelemetry.proto.trace.v1.Span spans = 2;
    • addSpansBuilder

      public Span.Builder addSpansBuilder(int index)
       A list of Spans that originate from an instrumentation scope.
       
      repeated .opentelemetry.proto.trace.v1.Span spans = 2;
    • getSpansBuilderList

      public List<Span.Builder> getSpansBuilderList()
       A list of Spans that originate from an instrumentation scope.
       
      repeated .opentelemetry.proto.trace.v1.Span spans = 2;
    • getSchemaUrl

      public String getSchemaUrl()
       The Schema URL, if known. This is the identifier of the Schema that the span data
       is recorded in. To learn more about Schema URL see
       https://opentelemetry.io/docs/specs/otel/schemas/#schema-url
       This schema_url applies to all spans and span events in the "spans" field.
       
      string schema_url = 3;
      Specified by:
      getSchemaUrl in interface ScopeSpansOrBuilder
      Returns:
      The schemaUrl.
    • getSchemaUrlBytes

      public com.google.protobuf.ByteString getSchemaUrlBytes()
       The Schema URL, if known. This is the identifier of the Schema that the span data
       is recorded in. To learn more about Schema URL see
       https://opentelemetry.io/docs/specs/otel/schemas/#schema-url
       This schema_url applies to all spans and span events in the "spans" field.
       
      string schema_url = 3;
      Specified by:
      getSchemaUrlBytes in interface ScopeSpansOrBuilder
      Returns:
      The bytes for schemaUrl.
    • setSchemaUrl

      public ScopeSpans.Builder setSchemaUrl(String value)
       The Schema URL, if known. This is the identifier of the Schema that the span data
       is recorded in. To learn more about Schema URL see
       https://opentelemetry.io/docs/specs/otel/schemas/#schema-url
       This schema_url applies to all spans and span events in the "spans" field.
       
      string schema_url = 3;
      Parameters:
      value - The schemaUrl to set.
      Returns:
      This builder for chaining.
    • clearSchemaUrl

      public ScopeSpans.Builder clearSchemaUrl()
       The Schema URL, if known. This is the identifier of the Schema that the span data
       is recorded in. To learn more about Schema URL see
       https://opentelemetry.io/docs/specs/otel/schemas/#schema-url
       This schema_url applies to all spans and span events in the "spans" field.
       
      string schema_url = 3;
      Returns:
      This builder for chaining.
    • setSchemaUrlBytes

      public ScopeSpans.Builder setSchemaUrlBytes(com.google.protobuf.ByteString value)
       The Schema URL, if known. This is the identifier of the Schema that the span data
       is recorded in. To learn more about Schema URL see
       https://opentelemetry.io/docs/specs/otel/schemas/#schema-url
       This schema_url applies to all spans and span events in the "spans" field.
       
      string schema_url = 3;
      Parameters:
      value - The bytes for schemaUrl to set.
      Returns:
      This builder for chaining.
    • setUnknownFields

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

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