Skip to main content

AsLog

Trait AsLog 

Source
pub trait AsLog: Sealed {
    type Log;

    // Required method
    fn as_log(&self) -> Self::Log;
}
Expand description

Trait implemented for tracing types that can be converted to a log equivalent.

Required Associated Types§

Source

type Log

The log type that this type can be converted into.

Required Methods§

Source

fn as_log(&self) -> Self::Log

Returns the log equivalent of self.

Dyn Compatibility§

This trait is dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety".

Implementations on Foreign Types§

Source§

impl AsLog for Level

Source§

impl AsLog for LevelFilter

Source§

type Log = LevelFilter

Source§

fn as_log(&self) -> Self::Log

Source§

impl<'a> AsLog for Metadata<'a>

Source§

type Log = Metadata<'a>

Source§

fn as_log(&self) -> Self::Log

Implementors§