3

Seems Validating multiple fields in JSF2 using postValidate event is not a best practice.

<f:event type="postValidate" listener="#{bean.validate}" />

Because this is tightly coupled with bean and we can re-use this validation in another page.

Could you please suggest me an alternative way of validation implementation which will be re-used, more generic and de-coupled with bean.

Sam R.
  • 16,027
  • 12
  • 69
  • 122
  • 3
    This is essentially already answered here: http://stackoverflow.com/questions/6282466/jsf2-0-doesnt-support-cross-field-validation-is-there-a-workaround/6282509#6282509 – BalusC Mar 15 '13 at 13:11

0 Answers0