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=-0.3 required=5.0 tests=BAYES_00, REPLYTO_WITHOUT_TO_CC autolearn=no autolearn_force=no version=3.4.4 X-Google-Thread: 103376,cc6427a95410cecf X-Google-Attributes: gid103376,domainid0,public,usenet X-Google-Language: ENGLISH,ASCII-7-bit Path: g2news2.google.com!news1.google.com!border1.nntp.dca.giganews.com!nntp.giganews.com!newsfeed00.sul.t-online.de!t-online.de!newsfeed-0.progon.net!progon.net!newsfeed.ision.net!newsfeed2.easynews.net!ision!newsfeed.arcor.de!newsspool2.arcor-online.net!news.arcor.de.POSTED!not-for-mail Date: Thu, 11 Sep 2008 16:10:40 +0200 From: Georg Bauhaus Reply-To: rm.tsoh+bauhaus@maps.futureapps.de User-Agent: Thunderbird 2.0.0.16 (Windows/20080708) MIME-Version: 1.0 Newsgroups: comp.lang.ada Subject: Re: XML/Ada - reading an attribute References: <48c9109f$0$90269$14726298@news.sunsite.dk> In-Reply-To: <48c9109f$0$90269$14726298@news.sunsite.dk> Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit Message-ID: <48c926ea$0$6556$9b4e6d93@newsspool4.arcor-online.net> Organization: Arcor NNTP-Posting-Date: 11 Sep 2008 16:10:50 CEST NNTP-Posting-Host: 97fd9dbb.newsspool4.arcor-online.net X-Trace: DXC=76jVI]0HgLWU6b:FjPaGjQ4IUKZLh>_cHTX3j]mBLYcEKoJG^ X-Complaints-To: usenet-abuse@arcor.de Xref: g2news2.google.com comp.lang.ada:7710 Date: 2008-09-11T16:10:50+02:00 List-Id: Thomas Locke wrote: > Hey group, > > I'm currently doing this in order to read the seconds attribute of the > simulation_length element: http://pastebin.ca/1199908 > > My current solution is working quite well and it gets the job done, I'm > just wondering if there's a "better" way. http://www.mckae.com/xia.html might make access more comfortable. At the opposite end, not necessarily a better way, but have you considered a SAX style parser with callbacks triggered by certain nodes? I have found that useful when processing lots of similar subtrees of the XML document. No need for a DOM then.