TraceFlags class

Trace flags for a SpanContext. These flags are used to control tracing behavior. TraceFlags follows the W3C Trace Context specification.

Constructors

TraceFlags.fromString(String hex)
Creates TraceFlags from a hexadecimal string representation.
factory

Properties

asByte → int
Returns the byte representation of the TraceFlags
no setter
hashCode → int
The hash code for this object.
no setteroverride
isSampled → bool
Returns true if the sampled flag is set
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
Convert flags to hex string
override
withSampled(bool isSampled) → TraceFlags
Returns a new trace flags with sampling enabled or disabled.

Operators

operator ==(Object other) → bool
The equality operator.
override

Static Properties

none ↔ TraceFlags
A TraceFlags instance with no flags set (not sampled).
getter/setter pair
sampled ↔ TraceFlags
A TraceFlags instance with the sampled flag set.
getter/setter pair

Constants

NONE_FLAG → const int
Flag indicating no sampling. Value is 0x0.
SAMPLED_FLAG → const int
Flag indicating the trace is sampled. Value is 0x1.