pub struct Tracer { /* private fields */ }Expand description
Performance tracer with interior mutability
Implementations§
Source§impl Tracer
impl Tracer
Sourcepub fn with_config(config: TraceConfig) -> Self
pub fn with_config(config: TraceConfig) -> Self
Create a tracer with custom config
Sourcepub fn config(&self) -> &TraceConfig
pub fn config(&self) -> &TraceConfig
Get configuration
Sourcepub fn is_recording(&self) -> bool
pub fn is_recording(&self) -> bool
Check if recording
Sourcepub fn active_span_count(&self) -> usize
pub fn active_span_count(&self) -> usize
Get current span count
Sourcepub fn completed_span_count(&self) -> usize
pub fn completed_span_count(&self) -> usize
Get completed span count
Trait Implementations§
Auto Trait Implementations§
impl Freeze for Tracer
impl !RefUnwindSafe for Tracer
impl !Send for Tracer
impl !Sync for Tracer
impl Unpin for Tracer
impl UnsafeUnpin for Tracer
impl !UnwindSafe for Tracer
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> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§impl<T> Pointable for T
impl<T> Pointable for T
Source§impl<R, P> ReadPrimitive<R> for P
impl<R, P> ReadPrimitive<R> for P
Source§fn read_from_little_endian(read: &mut R) -> Result<Self, Error>
fn read_from_little_endian(read: &mut R) -> Result<Self, Error>
Read this value from the supplied reader. Same as
ReadEndian::read_from_little_endian().