Package io.opentelemetry.sdk.trace.data
Class ImmutableStatusData
- java.lang.Object
-
- io.opentelemetry.sdk.trace.data.ImmutableStatusData
-
- All Implemented Interfaces:
StatusData
- Direct Known Subclasses:
AutoValue_ImmutableStatusData
@Immutable abstract class ImmutableStatusData extends java.lang.Object implements StatusData
Defines the status of aSpanby providing a standardStatusCodein conjunction with an optional descriptive message. Instances ofStatusare created by starting with the template for the appropriateStatusCodeand supplementing it with additional information:Status.NOT_FOUND.withDescription("Could not find 'important_file.txt'");
-
-
Field Summary
Fields Modifier and Type Field Description (package private) static StatusDataERRORThe operation contains an error.(package private) static StatusDataOKThe operation has been validated by an Application developers or Operator to have completed successfully.(package private) static StatusDataUNSETThe default status.
-
Constructor Summary
Constructors Constructor Description ImmutableStatusData()
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method Description (package private) static StatusDatacreate(StatusCode statusCode, java.lang.String description)Creates a derived instance ofStatuswith the given description.private static StatusDatacreateInternal(StatusCode statusCode, java.lang.String description)-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface io.opentelemetry.sdk.trace.data.StatusData
getDescription, getStatusCode
-
-
-
-
Field Detail
-
OK
static final StatusData OK
The operation has been validated by an Application developers or Operator to have completed successfully.
-
UNSET
static final StatusData UNSET
The default status.
-
ERROR
static final StatusData ERROR
The operation contains an error.
-
-
Method Detail
-
create
static StatusData create(StatusCode statusCode, java.lang.String description)
Creates a derived instance ofStatuswith the given description.- Parameters:
description- the new description of theStatus.- Returns:
- The newly created
Statuswith the given description.
-
createInternal
private static StatusData createInternal(StatusCode statusCode, java.lang.String description)
-
-