From mboxrd@z Thu Jan 1 00:00:00 1970 X-Spam-Checker-Version: SpamAssassin 3.4.4 (2020-01-24) on polar.synack.me X-Spam-Level: X-Spam-Status: No, score=-1.9 required=5.0 tests=BAYES_00 autolearn=ham autolearn_force=no version=3.4.4 X-Google-Language: ENGLISH,ASCII-7-bit X-Google-Thread: 103376,ad0779dc60e28dee X-Google-Attributes: gid103376,public X-Google-ArrivalTime: 2003-03-10 18:04:17 PST Path: archiver1.google.com!news1.google.com!newsfeed.stanford.edu!postnews1.google.com!not-for-mail From: mheaney@on2.com (Matthew Heaney) Newsgroups: comp.lang.ada Subject: Re: Data Structure Choice for DOM Date: 10 Mar 2003 18:04:16 -0800 Organization: http://groups.google.com/ Message-ID: <1ec946d1.0303101804.50d5104f@posting.google.com> References: NNTP-Posting-Host: 66.162.65.162 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 8bit X-Trace: posting.google.com 1047348257 28882 127.0.0.1 (11 Mar 2003 02:04:17 GMT) X-Complaints-To: groups-abuse@google.com NNTP-Posting-Date: 11 Mar 2003 02:04:17 GMT Xref: archiver1.google.com comp.lang.ada:35160 Date: 2003-03-11T02:04:17+00:00 List-Id: "chris.danx" wrote in message news:... > > In the DOM Level 3 spec, a NamedNodeMap is defined. What's the best way > to implement this? I'm implementing an OO version of the DOM Level 3 > spec (in Ada*) and this one is posing a problem just choosing the right > implementation. Under considering is a chained hash table and an AVL > tree. Both have their advantage but there may be a more appropriate > choice of which I'm not aware. The Charles library has both kinds of map structures. charles.maps.sorted.unbounded charles.maps.hashed.unbounded There are also versions that have type String as the key. charles.maps.sorted.strings.unbounded charles.maps.hashed.strings.unbounded The sorted versions is implemented using a red-black tree, which has properties similar to an AVL tree. http://home.earthlink.net/~matthewjheaney/charles/index.html