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.
  • 15,559
  • 11
  • 64
  • 114
  • 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