pub fn init_with_listener(listener: Box<dyn LogListener>)Expand description
Initializes the logging system with a listener.
Note that the init! macro is the preferred method to do this in the public API.
use breadcrumbs::{init_with_listener, LogListener};
struct MyLogListener;
impl LogListener for MyLogListener {
fn on_log(&mut self, log: breadcrumbs::Log) {
println!("{}", log);
}
}
init_with_listener(Box::new(MyLogListener));