pub trait StatisticsLogFormatter:
Sync
+ Send
+ 'static {
// Required method
fn log_stat(logger: &StatisticsLogger, stat: &StatLogData<'_>)
where Self: Sized;
}Expand description
A trait object to allow users to customise the format of stats when logged.
Required Methods§
Sourcefn log_stat(logger: &StatisticsLogger, stat: &StatLogData<'_>)where
Self: Sized,
fn log_stat(logger: &StatisticsLogger, stat: &StatLogData<'_>)where
Self: Sized,
The formatting callback. This should take the statistic information and log it through the provided logger in the relevant format.
The DefaultStatisticsLogFormatter provides a basic format, or users can override the
format of the generated logs by providing an object that implements this trait in the
StatsConfig.
Dyn Compatibility§
This trait is dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety".