- From: Fred L. Drake, Jr. <fdrake@acm.org>
- Date: Wed, 11 Jul 2001 14:56:45 -0400 (EDT)
- To: "Allen, Michael B (RSCH)" <Michael_B_Allen@ml.com>
- Cc: "'www-dom@w3c.org'" <www-dom@w3c.org>
Allen, Michael B (RSCH) writes: > Is a NodeNamedMap ever used to hold anything but the Attrs of an > Element? Yes -- they are used to hold the entity and notation definitions in the DocumentType node. > Might an Attr be an entry in more than one > NamedNodeMap? A simply way to implement NamedNodeMap in > c is to just add nextAttr and previousAtt members to Node and > make NamedNodeMap a struct like: ... > If the answers to the above questions are "no" I don't see a problem > with this technique. Do you? I don't think Attr nodes can appear in more than one map. Whether or not this is a reasonable implementation approach depends on how you handle default attributes derived from the DTD; if you support a DTD, this may not be a good approach, especially if you support DOM mutation. (And yes, I think mutation should be a separate feature from simple read-access! But that's a different topic.) -Fred -- Fred L. Drake, Jr. <fdrake at acm.org> PythonLabs at Digital Creations
Received on Wednesday, 11 July 2001 14:58:49 UTC