ToUppercase

Trait ToUppercase 

Source
pub trait ToUppercase<'a> {
    // Required methods
    fn to_uppercase_cow(self) -> Cow<'a, str>;
    fn to_ascii_uppercase_cow(self) -> Cow<'a, str>;
}
Available on crate feature alloc only.
Expand description

To extend str and Cow<str> to have to_uppercase_cow and to_ascii_uppercase_cow methods.

Required Methods§

Source

fn to_uppercase_cow(self) -> Cow<'a, str>

Converts the string to its uppercase form (Unicode-aware), returning a Cow<str> to avoid allocation when possible.

Source

fn to_ascii_uppercase_cow(self) -> Cow<'a, str>

Converts the string to its ASCII uppercase form, returning a Cow<str> to avoid allocation when possible.

Implementations on Foreign Types§

Source§

impl<'a> ToUppercase<'a> for &'a str

Source§

impl<'a> ToUppercase<'a> for Cow<'a, str>

Implementors§