Trait std::ascii::StrAsciiExt
pub trait StrAsciiExt { fn to_ascii_upper(&self) -> ~str; fn to_ascii_lower(&self) -> ~str; fn eq_ignore_ascii_case(&self, other: &str) -> bool; }
Extension methods for ASCII-subset only operations on string slices
Required Methods
fn to_ascii_upper(&self) -> ~str
Makes a copy of the string in ASCII upper case: ASCII letters 'a' to 'z' are mapped to 'A' to 'Z', but non-ASCII letters are unchanged.
fn to_ascii_lower(&self) -> ~str
Makes a copy of the string in ASCII lower case: ASCII letters 'A' to 'Z' are mapped to 'a' to 'z', but non-ASCII letters are unchanged.
fn eq_ignore_ascii_case(&self, other: &str) -> bool
Check that two strings are an ASCII case-insensitive match.
Same as to_ascii_lower(a) == to_ascii_lower(b)
,
but without allocating and copying temporary strings.
Implementors
impl<'a> StrAsciiExt for &'a str