Hi

On Jan 16, 2006, at 11:11 AM, Emmanouil Batsis wrote:
Hi all,

Is anyone using xdoclet validator tags with ValidatorActionForms to generate different validation rule-sets per action? Is it even possible?


As far as i know it is not possible. And in my humble opinion it's not desirable.

I believe that each part of the code (class, method, etc) should be used to do just one thing. So using a single ValidatorActionForm to generate several validation rules seems too me a little bit tangled, since it might get hard to discern which validation rule goes to which action (at the setter doc comment).

You can code another ValidatorActionForm. Having one ValidatorActionForm with its validation attached (just one) keeps the design simple and easier to maintain. When coding it seems like unnecessary work when you think you can re-use a class' bean patterns and just generate different validation rules, but this might get messy when maintenance time starts.

Regards

Marcelo Morales


---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to