pub struct LogHandler;Expand description
Emits one eprintln! line per event. Suitable for development; not
recommended for production hot paths (stderr writes hit a global lock
in libstd).
Trait Implementations§
Source§impl Clone for LogHandler
impl Clone for LogHandler
Source§fn clone(&self) -> LogHandler
fn clone(&self) -> LogHandler
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreimpl Copy for LogHandler
Source§impl Debug for LogHandler
impl Debug for LogHandler
Source§impl Default for LogHandler
impl Default for LogHandler
Source§fn default() -> LogHandler
fn default() -> LogHandler
Returns the “default value” for a type. Read more
Source§impl WatermarkHandler for LogHandler
Available on crate feature std only.
impl WatermarkHandler for LogHandler
Available on crate feature
std only.Source§fn on_warn(&self, event: WatermarkEvent)
fn on_warn(&self, event: WatermarkEvent)
Called once per crossing of the
warn_pct threshold (rising edge).Source§fn on_critical(&self, event: WatermarkEvent)
fn on_critical(&self, event: WatermarkEvent)
Called once per crossing of the
critical_pct threshold (rising edge).Source§fn on_oom(&self, event: WatermarkEvent)
fn on_oom(&self, event: WatermarkEvent)
Called when an allocation returns
AllocError.Auto Trait Implementations§
impl Freeze for LogHandler
impl RefUnwindSafe for LogHandler
impl Send for LogHandler
impl Sync for LogHandler
impl Unpin for LogHandler
impl UnsafeUnpin for LogHandler
impl UnwindSafe for LogHandler
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