Skip to main content

Module string

Module string 

Source
Expand description

String-content rules.

Each rule applies to any S: AsRef<str>, so it accepts &str, String, and borrowed string types alike. They check character content only; combine with the length rules (via And) when you also need a length bound.

Structsยง

Alphanumeric
Accepts strings whose characters are all alphanumeric.
Ascii
Accepts strings whose characters are all ASCII.
Trimmed
Accepts strings with no leading or trailing whitespace.