pub trait ToStrings {
    // Required method
    fn to_strings(&self) -> Vec<String>;
    // Provided method
    fn to_absolute_strings(&self) -> Vec<String> { ... }
}Expand description
Trait for converting a vector of PathBufs to a vector of strings
Required Methods§
Sourcefn to_strings(&self) -> Vec<String>
 
fn to_strings(&self) -> Vec<String>
Convert a vector of string slices to a vector of string values of paths
This is a convenience that I find myself wanting to use in a lot of places.
Adding a to_strings method to the Vec<PathBuf> types seems like a good idea.
§Example
use acorn_lib::util::ToStrings;
let paths = vec![PathBuf::from("foo"), PathBuf::from("bar"), PathBuf::from("baz")];
assert!(paths.to_strings().contains(&"foo".to_string()));Provided Methods§
Sourcefn to_absolute_strings(&self) -> Vec<String>
 
fn to_absolute_strings(&self) -> Vec<String>
Convert a vector of string slices to a vector of string values of absolute paths