Trait validators::traits::ValidateString
source · pub trait ValidateString {
type Error;
type Output;
fn parse_string<S: Into<String>>(s: S) -> Result<Self::Output, Self::Error>;
fn parse_str<S: AsRef<str>>(s: S) -> Result<Self::Output, Self::Error>;
fn validate_str<S: AsRef<str>>(s: S) -> Result<(), Self::Error>;
}
Expand description
Validate and deserialize strings.