Skip to main content

Formattable

Trait Formattable 

Source
pub trait Formattable {
    // Required methods
    fn headers() -> Vec<String>;
    fn row(&self) -> Vec<String>;
}
Expand description

Trait for types that can be rendered in table or CSV format.

Required Methods§

Source

fn headers() -> Vec<String>

Column headers for table/CSV output.

Source

fn row(&self) -> Vec<String>

Row values corresponding to the headers.

Dyn Compatibility§

This trait is not dyn compatible.

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

Implementors§