pub trait ValidateEmail {
    // Required method
    fn as_email_string(&self) -> Option<Cow<'_, str>>;
    // Provided method
    fn validate_email(&self) -> bool { ... }
}Expand description
Validates whether the given string is an email based on the HTML5 spec. RFC 5322 is not practical in most circumstances and allows email addresses that are unfamiliar to most users.