Struct slog_term::CompactFormatBuilder
source · pub struct CompactFormatBuilder<D>where
D: Decorator,{ /* private fields */ }
Expand description
Streamer builder
Implementations§
source§impl<D> CompactFormatBuilder<D>where
D: Decorator,
impl<D> CompactFormatBuilder<D>where
D: Decorator,
sourcepub fn use_utc_timestamp(self) -> Self
pub fn use_utc_timestamp(self) -> Self
Use the UTC time zone for the timestamp
sourcepub fn use_local_timestamp(self) -> Self
pub fn use_local_timestamp(self) -> Self
Use the local time zone for the timestamp (default)
sourcepub fn use_custom_timestamp<F>(self, f: F) -> Selfwhere
F: ThreadSafeTimestampFn,
pub fn use_custom_timestamp<F>(self, f: F) -> Selfwhere
F: ThreadSafeTimestampFn,
Provide a custom function to generate the timestamp
sourcepub fn use_custom_header_print<F>(self, f: F) -> Selfwhere
F: ThreadSafeHeaderFn,
pub fn use_custom_header_print<F>(self, f: F) -> Selfwhere
F: ThreadSafeHeaderFn,
Provide a function that print the header
If not used, slog_term::print_msg_header
will be used
sourcepub fn build(self) -> CompactFormat<D>
pub fn build(self) -> CompactFormat<D>
Build the streamer
Auto Trait Implementations§
impl<D> RefUnwindSafe for CompactFormatBuilder<D>where
D: RefUnwindSafe,
impl<D> Send for CompactFormatBuilder<D>where
D: Send,
impl<D> Sync for CompactFormatBuilder<D>where
D: Sync,
impl<D> Unpin for CompactFormatBuilder<D>where
D: Unpin,
impl<D> UnwindSafe for CompactFormatBuilder<D>where
D: UnwindSafe,
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