Class SpanAttributes.Builder
-
- All Implemented Interfaces:
public final class SpanAttributes.BuilderA builder for SpanAttributes.
-
-
Method Summary
-
-
Method Detail
-
name
final SpanAttributes.Builder name(String name)
Name of the span, for display purposes only
-
name
final SpanAttributes.Builder name(Optional<String> name)
Alias for calling Builder.name with
name.orElse(null).
-
name
final SpanAttributes.Builder name(JsonField<String> name)
Sets Builder.name to an arbitrary JSON value.
You should usually call Builder.name with a well-typed String value instead. This method is primarily for setting the field to an undocumented or not yet supported value.
-
type
final SpanAttributes.Builder type(SpanType type)
Type of the span, for display purposes only
-
type
final SpanAttributes.Builder type(Optional<SpanType> type)
Alias for calling Builder.type with
type.orElse(null).
-
type
final SpanAttributes.Builder type(JsonField<SpanType> type)
Sets Builder.type to an arbitrary JSON value.
You should usually call Builder.type with a well-typed SpanType value instead. This method is primarily for setting the field to an undocumented or not yet supported value.
-
additionalProperties
final SpanAttributes.Builder additionalProperties(Map<String, JsonValue> additionalProperties)
-
putAdditionalProperty
final SpanAttributes.Builder putAdditionalProperty(String key, JsonValue value)
-
putAllAdditionalProperties
final SpanAttributes.Builder putAllAdditionalProperties(Map<String, JsonValue> additionalProperties)
-
removeAdditionalProperty
final SpanAttributes.Builder removeAdditionalProperty(String key)
-
removeAllAdditionalProperties
final SpanAttributes.Builder removeAllAdditionalProperties(Set<String> keys)
-
build
final SpanAttributes build()
Returns an immutable instance of SpanAttributes.
Further updates to this Builder will not mutate the returned instance.
-
-
-
-