Trait FacetPretty

Source
pub trait FacetPretty: Facet {
    // Required methods
    fn pretty(&self) -> PrettyDisplay<'_, Self>;
    fn pretty_with(&self, printer: PrettyPrinter) -> PrettyDisplay<'_, Self>;
}
Expand description

Extension trait for Facet types to easily pretty-print them

Required Methods§

Source

fn pretty(&self) -> PrettyDisplay<'_, Self>

Get a displayable wrapper that pretty-prints this value

Source

fn pretty_with(&self, printer: PrettyPrinter) -> PrettyDisplay<'_, Self>

Get a displayable wrapper with custom printer settings

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§

Source§

impl<T: Facet> FacetPretty for T