How to specify a validator for an input component inside a composite component?

后端 未结 3 1201
天命终不由人
天命终不由人 2020-12-06 07:44

Should I register a custom validator in faces-config.xml if I\'m using JSF 2.0.4? My custom validator uses Validator interface which is javax.faces.valida

3条回答
  •  难免孤独
    2020-12-06 08:29

    No. That is not necessary with Jsf 2.0. Just annotate your validator with @FacesValidator. The annotation registers your validator automatically. No xml needed.

提交回复
热议问题