W3C home > Mailing lists > Public > www-dom@w3.org > October to December 2001

Re: Which Exception should be raised when multiple codes are possible

From: Joseph Kesselman <keshlam@us.ibm.com>
Date: Mon, 5 Nov 2001 09:28:19 -0500
To: <www-dom@w3.org>
Message-ID: <OFBE661B81.8025678C-ON85256AFB.004EA4A8@pok.ibm.com>

>So, as a conclusion, it is possible to raise any one of the exceptions
>that apply, and DOM implementors can choose the one that is easiest to
>implement.

As far as what's actually said in the REC goes.. yes, I believe that's
true.

I think there are strong expectations that the "most appropriate"
DOMException  will be chosen.  Generally DOM code shouldn't be throwing
exceptions unless the caller did something wrong, and you want to give them
the clearest information you can so they can fix their code.

Which is most appropriate in every possible case is not  perfectly nailed
down.  The DOM test cases (now under develoment) may help to focus this
more precisely.
.
______________________________________
Joe Kesselman  / IBM Research
Received on Monday, 5 November 2001 09:28:57 GMT

This archive was generated by hypermail 2.2.0+W3C-0.50 : Friday, 22 June 2012 06:13:55 GMT