Joseph Kesselman wrote:


I'm afraid that turns out not to be correct, Elliotte.

The DOM does not require namespace declaration attributes to be present. They typically are produced when a parser builds the DOM,, but the DOM is designed to operate perfectly happily without them.


Well sometimes it does. Sometimes it doesn't. That's the problem. The DOM most definitely does not operate perfectly happily without them in any practical situation. And since it allows both they can get out of sync. This is a very common bug that keeps coming up over and over again in all sorts of areas. This is a major design flaw in DOM.

The only way to assure that things actually work in practice in DOM Level 2, without resorting to non-standard classes and implementation specific details, is to provide both namespace properties for elements and attributes *and* Attr objects representing namespace declarations, and be very careful that you don't let them get out of sync. DOM Level 3 tries to Spackle over the cracks caused by this architectural flaw, but does not actually fix it. :-(

--
Elliotte Rusty Harold
[EMAIL PROTECTED]


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



Reply via email to