matchesEmail

Whether a string matches an email according to the W3C HTML5 spec.

Note: As per spec, this function performs a punycode encoding of the domain part of the email address. In the JVM, unless ICU4J is found in the classpath, Java's IDN will be used for this purpose. Although likely sufficient for most addresses, this is not fully compliant with the specification as it uses the legacy IDNA2003 instead of UTS #46.