Trait StringExt

Source
pub trait StringExt {
    // Required methods
    fn is_lowercase(&self) -> bool;
    fn starts_with_lowercase(&self) -> bool;
    fn to_lowercase_first(&self) -> String;
    fn to_uppercase_first(&self) -> String;
}
Expand description

Additional methods for strings

Required Methods§

Source

fn is_lowercase(&self) -> bool

Checks if the string is all lowercase

Source

fn starts_with_lowercase(&self) -> bool

Checks if a string starts with a lowercase character

Source

fn to_lowercase_first(&self) -> String

Returns a new string starting with a first character in lowercase

Source

fn to_uppercase_first(&self) -> String

Returns a new string starting with a first character in uppercase

Implementations on Foreign Types§

Source§

impl StringExt for str

Implementors§