TraceId class
A trace identifier - a 16-byte array with an ID in a base-16 hex format. TraceId follows the W3C Trace Context specification.
- Annotations
-
- @immutable
Properties
- bytes → Uint8List
-
The raw bytes of the trace ID
no setter
- hashCode → int
-
The hash code for this object.
no setteroverride
- hexString → String
-
Returns the lowercase base16 (hex) representation of the TraceId
no setter
- isValid → bool
-
Returns true if this TraceId is valid (not zero)
no setter
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
Methods
-
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
toString(
) → String -
A string representation of this object.
override
Operators
-
operator ==(
Object other) → bool -
The equality operator.
override
Static Properties
- invalidTraceIdBytes → Uint8List
-
A trace ID consisting of all zeros, representing an invalid trace ID.
final
Constants
- traceIdLength → const int
- The number of bytes in a trace ID. Per the OpenTelemetry specification, trace IDs must be 16 bytes (128 bits).