Skip to main content

ListsToString

Trait ListsToString 

Source
pub trait ListsToString {
    // Required method
    fn lists_to_string(
        &self,
        intra_separator: &str,
        inter_separator: &str,
    ) -> String;
}
Expand description

Extension trait to convert a list of lists of displayable items into a single string. For example, vec![vec![1, 2], vec![3]].lists_to_string(", ", " | ") will produce the string "[1, 2] | [3]".

Required Methods§

Source

fn lists_to_string( &self, intra_separator: &str, inter_separator: &str, ) -> String

Implementors§

Source§

impl<H, I, J> ListsToString for J
where for<'a> &'a I: IntoIterator<Item = &'a H>, for<'a> &'a J: IntoIterator<Item = &'a I>, H: Display,