Class EmailValidator

  • All Implemented Interfaces:
    Validator<java.lang.String>, java.io.Serializable, java.util.function.BiFunction<java.lang.String,​ValueContext,​ValidationResult>

    public class EmailValidator
    extends RegexpValidator
    A string validator for e-mail addresses. The e-mail address syntax is not complete according to RFC 822 but handles the vast majority of valid e-mail addresses correctly.
    Since:
    8.0
    Author:
    Vaadin Ltd.
    See Also:
    Serialized Form
    • Constructor Summary

      Constructors 
      Constructor Description
      EmailValidator​(java.lang.String errorMessage)
      Creates a validator for checking that a string is a syntactically valid e-mail address.
    • Method Summary

      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
      • Methods inherited from interface java.util.function.BiFunction

        andThen
    • Constructor Detail

      • EmailValidator

        public EmailValidator​(java.lang.String errorMessage)
        Creates a validator for checking that a string is a syntactically valid e-mail address.
        Parameters:
        errorMessage - the message to display in case the value does not validate.