Trait LoggerBuilder

Source
pub trait LoggerBuilder<T> {
    // Required methods
    fn filter<F>(self, predicate: F, dependency: impl ToString) -> Self
       where F: 'static + Send + Sync + Fn(&Metadata<'_>) -> bool;
    fn with_color(self, colorized: impl Into<bool>) -> Self;
    fn with_format(
        self,
        format: fn(&Arguments<'_>, &Record<'_>, &mut Echo<'_>) -> String,
    ) -> Self;
    fn with_level(self, level: impl Into<LevelFilter>) -> Self;
    fn with_timestamp(self, b: impl Into<bool>) -> Self;
    fn build(self) -> T;
}

Required Methods§

Source

fn filter<F>(self, predicate: F, dependency: impl ToString) -> Self
where F: 'static + Send + Sync + Fn(&Metadata<'_>) -> bool,

Ajoute un filtre au système de log.

Source

fn with_color(self, colorized: impl Into<bool>) -> Self

Autorise ou non les logs à avoir les couleurs sur les informations contrôlées par notre système.

Source

fn with_format( self, format: fn(&Arguments<'_>, &Record<'_>, &mut Echo<'_>) -> String, ) -> Self

Le format du log.

Source

fn with_level(self, level: impl Into<LevelFilter>) -> Self

Le niveau de log.

Source

fn with_timestamp(self, b: impl Into<bool>) -> Self

Autorise ou non les logs à avoir un timestamp.

Source

fn build(self) -> T

Construction du logger.

Dyn Compatibility§

This trait is not dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.

Implementors§