TruncationStrategy

Trait TruncationStrategy 

Source
pub trait TruncationStrategy<T>{
    // Required method
    fn truncate(&self, target: &T, width: usize) -> Option<T::Output>;
}
Expand description

Functionality for truncating objects using some strategy.

Required Methods§

Source

fn truncate(&self, target: &T, width: usize) -> Option<T::Output>

Truncates target to width. Output should have a width equal to width.

Implementors§