How to use I18N with a custom validator?
This is my custom validator:
publicvoid validate(FacesContext context, UIComponent component, Object value)throws ValidatorException
{
Pattern pat=Pattern.compile(".+@.+\\.[a-z]+");
Matcher m= pat.matcher(value.toString());
if(!m.find())
{
FacesMessage message =new FacesMessage("Not a valid e-mail address");
thrownew ValidatorException(message);
}
}
Instead of providing the text "Not a valid e-mai address", I'd like to get the text out of my ApplicationResources property file.
How can I do this?
I know how to use it with the provided validators, but not with own custom ones
Please help me out, thanks

