pub struct FormatterRegistry { /* private fields */ }Expand description
Registry holding all formatters in priority order
Implementations§
Source§impl FormatterRegistry
impl FormatterRegistry
pub fn new() -> Self
Sourcepub fn format(&self, payload: &Value, message: &str)
pub fn format(&self, payload: &Value, message: &str)
Format the payload using the first matching formatter (legacy, uses payload inspection)
Sourcepub fn format_with_kind(
&self,
payload: &Value,
message: &str,
kind: Option<PayloadKind>,
)
pub fn format_with_kind( &self, payload: &Value, message: &str, kind: Option<PayloadKind>, )
Format the payload, optionally using a type hint for reliable matching.
Trait Implementations§
Auto Trait Implementations§
impl Freeze for FormatterRegistry
impl !RefUnwindSafe for FormatterRegistry
impl Send for FormatterRegistry
impl Sync for FormatterRegistry
impl Unpin for FormatterRegistry
impl !UnwindSafe for FormatterRegistry
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