W3C home > Mailing lists > Public > www-dom@w3.org > July to September 2003

Should Node.getChildNodes return Text of Attr?

From: Min Lee <minwoo75@hotmail.com>
Date: Thu, 5 Jun 2003 16:50:22 -0400 (EDT)
To: www-dom-ts@w3.org
Message-ID: <Law15-F53DSrfRIuZuk0002adc8@hotmail.com>

Hi all,

For the following XML:

  <?xml version='1.0'?><foo f='100'></foo>

when getChildNodes() is called on the root element, different 
implementations of DOM return NodeList of different length.

Xerces2-J and Crimson return a NodeList which contains 1 Text node of value 
DOM4j and Python's minidom return a NodeList containing no nodes.

This could be a problem if one's doing a comparison between two DOM 
implementations.  Unfortunately, this case is not covered by the current 
DOM-TS, and I couldn't find anything on DOM spec.  What should be the 
correct haviour?

Thanks in advance,


The new MSN 8: smart spam protection and 2 months FREE*  
Received on Wednesday, 2 July 2003 09:56:14 UTC

This archive was generated by hypermail 2.3.1 : Tuesday, 20 October 2015 10:46:11 UTC