Les Hazlewood wrote:

Whats wrong with doing:

public boolean isValid(Mapping mapping) {

    try {
        validate(mapping);
    } catch (MappingException me) {
        return false;
    }

    return true;
}

?

> (we could implement isValid(Mapping) in terms of validate(Mapping).

That line was exactly that ;)

Your other suggestions is also valid, but does more than needed - we just need to inform the user of
first error - Keeping it simple.


/max

> /max
>
>
> -------------------------------------------------------
> This SF.net email is sponsored by: IBM Linux Tutorials.
> Become an expert in LINUX or just sharpen your skills. Sign
> up for IBM's Free Linux Tutorials. Learn everything from the
> bash shell to sys admin. Click now!
> http://ads.osdn.com/?ad_id=1278&alloc_id=3371 <http://ads.osdn.com/?ad_id=1278&alloc_id=3371>> &op=click
>
> _______________________________________________
>
> hibernate-devel mailing list [EMAIL PROTECTED]
> https://lists.sourceforge.net/lists/listinfo/hibernate-devel
>





------------------------------------------------------- This SF.net email is sponsored by: IBM Linux Tutorials. Become an expert in LINUX or just sharpen your skills. Sign up for IBM's Free Linux Tutorials. Learn everything from the bash shell to sys admin. Click now! http://ads.osdn.com/?ad_id=1278&alloc_id=3371&op=click _______________________________________________ hibernate-devel mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/hibernate-devel

Reply via email to