On 1/30/06, Michael Neale [EMAIL PROTECTED] wrote:
yep validation like that definately should be done with an object and a
collection.
Like you say, have a ValidationList class, and .addValidationFail() method
that accumulates it. Exceptions generally are best avoided unless there is
Good point. We will have to mention it in the manual for Drools 3.
As a general rule, I would say don't throw any exceptions unless you want to
rudely interrupt execution - that pretty much applies to any framework. In
my naive youth, I use to use exceptions as means of communicating UI
Hi Paul,
in what framework are you using drools? I am using a struts plugin validator
which accesses a set of validation rules stored in my drl. This works very
nicely as it leaves the grunt work to the struts validator, ie. collecting the
errors and displaying them appropriately.
Agreed. It was poor design on my part as I realised that I couldn't do
all the validation in one hit and return all the errors for that
logical unit of work. Remedied that one now, reserved the exceptions
for something critical/fatal.
On 1/31/06, Michael Neale [EMAIL PROTECTED] wrote:
Good
I haven't used EJB3 yet, but your solution sounds good.
-Original Message-
From: Paul Smith [mailto:[EMAIL PROTECTED]
Sent: Tuesday, 31 January 2006 10:01 AM
To: user@drools.codehaus.org
Subject: Re: [drools-user] Stragegies for stacking Exceptions
I agree with you and pretty much came