pub struct NoopTracer { /* private fields */ }Available on crate feature
trace only.Expand description
A no-op instance of a Tracer.
Implementations§
Source§impl NoopTracer
impl NoopTracer
Trait Implementations§
Source§impl Clone for NoopTracer
impl Clone for NoopTracer
Source§fn clone(&self) -> NoopTracer
fn clone(&self) -> NoopTracer
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for NoopTracer
impl Debug for NoopTracer
Source§impl Default for NoopTracer
impl Default for NoopTracer
Source§fn default() -> NoopTracer
fn default() -> NoopTracer
Returns the “default value” for a type. Read more
Source§impl Tracer for NoopTracer
impl Tracer for NoopTracer
Source§fn start_with_context<T>(&self, name: T, parent_cx: &Context) -> Self::Span
fn start_with_context<T>(&self, name: T, parent_cx: &Context) -> Self::Span
Starts a new NoopSpan with a given context.
If the context contains a valid span, it’s span context is propagated.
Source§fn span_builder<T>(&self, name: T) -> SpanBuilder
fn span_builder<T>(&self, name: T) -> SpanBuilder
Starts a SpanBuilder.
Source§fn build_with_context(
&self,
_builder: SpanBuilder,
parent_cx: &Context,
) -> Self::Span
fn build_with_context( &self, _builder: SpanBuilder, parent_cx: &Context, ) -> Self::Span
Builds a NoopSpan from a SpanBuilder.
If the span builder or the context’s current span contains a valid span context, it is propagated.
Source§fn build(&self, builder: SpanBuilder) -> Self::Span
fn build(&self, builder: SpanBuilder) -> Self::Span
Create a span from a SpanBuilder
Auto Trait Implementations§
impl Freeze for NoopTracer
impl RefUnwindSafe for NoopTracer
impl Send for NoopTracer
impl Sync for NoopTracer
impl Unpin for NoopTracer
impl UnwindSafe for NoopTracer
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<T> FutureExt for T
impl<T> FutureExt for T
Source§fn with_context(self, otel_cx: Context) -> WithContext<Self>
fn with_context(self, otel_cx: Context) -> WithContext<Self>
Available on crate feature
trace only.Source§fn with_current_context(self) -> WithContext<Self>
fn with_current_context(self) -> WithContext<Self>
Available on crate feature
trace only.Source§impl<S, T> ObjectSafeTracer for T
impl<S, T> ObjectSafeTracer for T
Source§fn start_with_context_boxed(
&self,
name: Cow<'static, str>,
parent_cx: &Context,
) -> Box<dyn ObjectSafeSpan + Send + Sync>
Available on crate feature trace only.
fn start_with_context_boxed( &self, name: Cow<'static, str>, parent_cx: &Context, ) -> Box<dyn ObjectSafeSpan + Send + Sync>
trace only.Returns a trait object so the underlying implementation can be swapped out at runtime.
Source§fn build_with_context_boxed(
&self,
builder: SpanBuilder,
parent_cx: &Context,
) -> Box<dyn ObjectSafeSpan + Send + Sync>
Available on crate feature trace only.
fn build_with_context_boxed( &self, builder: SpanBuilder, parent_cx: &Context, ) -> Box<dyn ObjectSafeSpan + Send + Sync>
trace only.Returns a trait object so the underlying implementation can be swapped out at runtime.