pub trait SimplContainsTypewhere
Self: SimpleMatch,{
// Required methods
fn contains_type(&self, char_type: CharType<'_>) -> bool;
fn contains_types(&self, char_types: &[CharType<'_>]) -> bool;
fn starts_with_type(&self, char_type: CharType<'_>) -> bool;
fn starts_with_types(&self, char_types: &[CharType<'_>]) -> bool;
fn ends_with_type(&self, char_type: CharType<'_>) -> bool;
fn ends_with_types(&self, char_types: &[CharType<'_>]) -> bool;
}
Expand description
Test if character set (CharType) is in the string
Required Methods§
sourcefn contains_type(&self, char_type: CharType<'_>) -> bool
fn contains_type(&self, char_type: CharType<'_>) -> bool
contains characters in the specified set
sourcefn contains_types(&self, char_types: &[CharType<'_>]) -> bool
fn contains_types(&self, char_types: &[CharType<'_>]) -> bool
contains characters in the specified sets
sourcefn starts_with_type(&self, char_type: CharType<'_>) -> bool
fn starts_with_type(&self, char_type: CharType<'_>) -> bool
starts with one or more characters in the specified set
sourcefn starts_with_types(&self, char_types: &[CharType<'_>]) -> bool
fn starts_with_types(&self, char_types: &[CharType<'_>]) -> bool
starts with one or more characters in the specified set
sourcefn ends_with_type(&self, char_type: CharType<'_>) -> bool
fn ends_with_type(&self, char_type: CharType<'_>) -> bool
ends with one or more characters in the specified sets
sourcefn ends_with_types(&self, char_types: &[CharType<'_>]) -> bool
fn ends_with_types(&self, char_types: &[CharType<'_>]) -> bool
ends with one or more characters in the specified sets
Implementations on Foreign Types§
source§impl SimplContainsType for str
impl SimplContainsType for str
Implement character-set matching on &str/String
source§fn starts_with_type(&self, char_type: CharType<'_>) -> bool
fn starts_with_type(&self, char_type: CharType<'_>) -> bool
starts with one or more characters in the specified set
source§fn starts_with_types(&self, char_types: &[CharType<'_>]) -> bool
fn starts_with_types(&self, char_types: &[CharType<'_>]) -> bool
starts with one or more characters in the specified set
source§fn ends_with_type(&self, char_type: CharType<'_>) -> bool
fn ends_with_type(&self, char_type: CharType<'_>) -> bool
ends with one or more characters in the specified sets
source§fn ends_with_types(&self, char_types: &[CharType<'_>]) -> bool
fn ends_with_types(&self, char_types: &[CharType<'_>]) -> bool
ends with one or more characters in the specified sets