Struct tracing_subscriber::registry::SpanRef [−][src]
pub struct SpanRef<'a, R: LookupSpan<'a>> { /* fields omitted */ }
Expand description
Implementations
Returns a static reference to the span’s metadata.
Returns the ID of this span’s parent, or None
if this span is the root
of its trace tree.
Returns a SpanRef
describing this span’s parent, or None
if this
span is the root of its trace tree.
Returns an iterator over all parents of this span, starting with the immediate parent.
The iterator will first return the span’s immediate parent, followed by that span’s parent, followed by that span’s parent, and so on, until a it reaches a root span.
Returns an iterator over all parents of this span, starting with the root of the trace tree.
The iterator will return the root of the trace tree, followed by the next span, and then the next, until this span’s immediate parent is returned.
Note: if the “smallvec” feature flag is not enabled, this may allocate.
Returns a reference to this span’s Extensions
.
The extensions may be used by Layer
s to store additional data
describing the span.
Returns a mutable reference to this span’s Extensions
.
The extensions may be used by Layer
s to store additional data
describing the span.
Trait Implementations
Auto Trait Implementations
impl<'a, R> RefUnwindSafe for SpanRef<'a, R> where
R: RefUnwindSafe,
<R as LookupSpan<'a>>::Data: RefUnwindSafe,
impl<'a, R> Unpin for SpanRef<'a, R> where
<R as LookupSpan<'a>>::Data: Unpin,
impl<'a, R> UnwindSafe for SpanRef<'a, R> where
R: RefUnwindSafe,
<R as LookupSpan<'a>>::Data: UnwindSafe,