pub trait StringLike {
// Required method
fn to_str(&self) -> Result<&str, Utf8Error>;
// Provided methods
fn to_str_unchecked(&self) -> &str { ... }
fn to_string(&self) -> Result<String, Utf8Error> { ... }
fn to_string_unchecked(&self) -> String { ... }
}