[Advanced-java] How do I retrieve attributes in correct
order from a DOM?
Kathy Van Stone
kvs at acm.org
Thu Apr 13 08:09:43 PDT 2006
At 10:44 AM 4/13/2006, Prashant Parashar wrote:
>Hi,
>How do I retrieve attributes in correct order from a DOM?
By the specification (see http://www.w3.org/TR/REC-xml/#NT-STag) the
order or attributes is not supposed to be significant, so it unlikely
that any parser will preserve their order. There is no "correct" order to get.
What is your document that the order of the attributes matters?
Generally if you need ordering, you use a list of elements.
-Kathy Van Stone
kvs at acm.org
More information about the Advanced-java
mailing list