On Thu, 20 Mar 2003, Carsten Ziegeler wrote:

> Hi Stephan,
>
> you don't have to ask for changes (if they make sense). I don't
> own the code :)

I want to be sure ;-)

> So, making the code more understandable is good.
>
> > From: Stephan Michels [mailto:[EMAIL PROTECTED]
> >
> > can I move the part where you generate the validity objects
> > into a separate method, like generateValidities() ?
> > I whould like to enhance the profiler components to measure
> > the setup() time.
> >
> > Thanks.
> >
> > BTW, can you add a check for null in AbstractAggregatedValidity.add().
> > I got sometimes NPEs in AggregatedValidity.isValid(), and don't know which
> > Component add a Null validity.
> >
> I personally would rather search for the problem (or component) that
> tries to add a null validity. By adding a check, the stacktrace should
> show where the problem lies.
> If you add the extra check, we have to fix the problem and have to
> remove the check before release anyway.

Hmm, I'll think that I'm not the only one, who went into the trap. You're
right returning a null validity hurts the contract, this will cause an
exception. But a NPE in isValid() doesn't help searching the problem.

Stephan.

Reply via email to