Package com.sun.faces.taglib.jsf_core
Class RegexValidatorTag
java.lang.Object
jakarta.servlet.jsp.tagext.TagSupport
jakarta.faces.webapp.ValidatorELTag
com.sun.faces.taglib.jsf_core.AbstractValidatorTag
com.sun.faces.taglib.jsf_core.RegexValidatorTag
- All Implemented Interfaces:
jakarta.servlet.jsp.tagext.IterationTag,jakarta.servlet.jsp.tagext.JspTag,jakarta.servlet.jsp.tagext.Tag,Serializable
public class RegexValidatorTag extends AbstractValidatorTag
Tag for the Regular Expression Validator. Can accept a regex pattern as a property - this will be used to validate
against.
- Author:
- driscoll
- See Also:
- Serialized Form
-
Field Summary
-
Constructor Summary
Constructors Constructor Description RegexValidatorTag() -
Method Summary
Modifier and Type Method Description protected ValidatorcreateValidator()Create and return a newValidatorto be registered on our surroundingUIComponent.voidsetPattern(jakarta.el.ValueExpression pattern)Set the Regular Expression to use for validation.Methods inherited from class com.sun.faces.taglib.jsf_core.AbstractValidatorTag
createValidator, setBinding, setValidatorId
-
Constructor Details
-
RegexValidatorTag
public RegexValidatorTag()
-
-
Method Details
-
setPattern
public void setPattern(jakarta.el.ValueExpression pattern)Set the Regular Expression to use for validation.- Parameters:
pattern- A regular expression - needs to be escaped, @see java.util.regex .
-
createValidator
Description copied from class:ValidatorELTagCreate and return a new
Validatorto be registered on our surroundingUIComponent.- Overrides:
createValidatorin classAbstractValidatorTag- Returns:
- the created
Validator - Throws:
jakarta.servlet.jsp.JspException- if a new instance cannot be created
-