pub struct Subscriber;
Expand description
A type that can be used to create a Subscriber
which collects tracing
spans and events and emits them in JSON.
This type is actually ZST and is only useful to call builder
to configure
a subscriber.
Implementations§
source§impl Subscriber
impl Subscriber
sourcepub fn builder() -> SubscriberBuilder
pub fn builder() -> SubscriberBuilder
Creates a SubscriberBuilder
which can be used to configure a Subscriber
.
§Examples
let subscriber = Subscriber::builder()
.with_max_level(tracing::Level::INFO)
.with_target(false)
.finish();
Auto Trait Implementations§
impl Freeze for Subscriber
impl RefUnwindSafe for Subscriber
impl Send for Subscriber
impl Sync for Subscriber
impl Unpin for Subscriber
impl UnwindSafe for Subscriber
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