Trait enso_flexer::prelude::logger::processor::Processor [−][src]
Expand description
The most primitive building block of a logger. Processor takes some input and returns some output, forming a message processing pipeline.
Processors can be chained together with the use of the Seq
processor. They can perform both
simple actions like formatting the logs or outputting them to console, as well as more complex
ones, like buffering them globally and dumping them on demand only. There are a lot of sample
processors defined in this module and its sub-modules.
Processors always implement the Default
trait, so it’s sufficient to construct them using
type-level mechanisms only. For example, one of the simplest usages of processors would be a
processor defined as Seq<Formatter<formatter::JsConsole>,Consumer<consumer::JsConsole>>
,
which for each input message first formats it and then prints it to the JavaScript console.
Associated Types
Loading content...Required methods
Loading content...Implementors
impl<C, Levels, Message> Processor<(Entry<Levels>, Option<Message>)> for Consumer<C> where
C: Definition<Levels, Message>,
[src]
impl<C, Levels, Message> Processor<(Entry<Levels>, Option<Message>)> for Consumer<C> where
C: Definition<Levels, Message>,
[src]impl<Fmt, Lvl> Processor<Entry<Lvl>> for Formatter<Fmt> where
Fmt: GenericDefinition<Lvl>,
[src]
impl<Fmt, Lvl> Processor<Entry<Lvl>> for Formatter<Fmt> where
Fmt: GenericDefinition<Lvl>,
[src]impl<Input, First, Second> Processor<Input> for BranchBuilder<First, Second> where
Input: Clone,
First: Processor<Input>,
Second: Processor<Input>,
[src]
impl<Input, First, Second> Processor<Input> for BranchBuilder<First, Second> where
Input: Clone,
First: Processor<Input>,
Second: Processor<Input>,
[src]impl<Input, First, Second> Processor<Input> for SeqBuilder<First, Second> where
First: Processor<Input>,
Second: Processor<<First as Processor<Input>>::Output>,
[src]
impl<Input, First, Second> Processor<Input> for SeqBuilder<First, Second> where
First: Processor<Input>,
Second: Processor<<First as Processor<Input>>::Output>,
[src]impl<P, Input> Processor<Input> for Global<P> where
P: GlobalProcessor,
<P as GlobalProcessor>::Processor: 'static,
<P as GlobalProcessor>::Processor: Processor<Input>,
[src]
impl<P, Input> Processor<Input> for Global<P> where
P: GlobalProcessor,
<P as GlobalProcessor>::Processor: 'static,
<P as GlobalProcessor>::Processor: Processor<Input>,
[src]