Interface HasValidity

    • Method Summary

      All Methods Instance Methods Abstract Methods 
      Modifier and Type Method Description
      boolean checkValidity()
      Returns false if the element is a candidate for constraint validation, and it does not satisfy its constraints.
      String getValidationMessage()
      A localized message that describes the validation constraints that the control does not satisfy (if any).
      elemental2.dom.ValidityState getValidity()
      The validity states that this element is in.
    • Method Detail

      • getValidationMessage

        String getValidationMessage()
        A localized message that describes the validation constraints that the control does not satisfy (if any). This is the empty string if the control is not a candidate for constraint validation (willValidate is false), or it satisfies its constraints.
        Returns:
        localized validation message
      • getValidity

        elemental2.dom.ValidityState getValidity()
        The validity states that this element is in.
        Returns:
        ValidityState
      • checkValidity

        boolean checkValidity()
        Returns false if the element is a candidate for constraint validation, and it does not satisfy its constraints. In this case, it also fires an invalid event at the element. It returns true if the element is not a candidate for constraint validation, or if it satisfies its constraints.
        Returns:
        true if input is valid