Velocity Reviews - Computer Hardware Reviews

Velocity Reviews > Newsgroups > Programming > XML > [xerces-c] How to access a particular node?

Reply
Thread Tools

[xerces-c] How to access a particular node?

 
 
Rene
Guest
Posts: n/a
 
      01-27-2004
Hi,

Newbie alert...
I'm using Xerces-C as a DOM parser.
I got it validating, and can retrieve/walk my XML nodes.
However, I'm missing some functionality.

Given this example XML file:

<companies>
<company1>
<address>
<street/>
<phone/>
</address>
<managers>
<ceo>
<name/>
<phone/>
</ceo>
<cio>
<name/>
<phone/>
</cio>
</managers>
</company1>
<company2>
<...>
</company2>
</companies>

When I want the phone# of company1 I can of course walk my nodes and
finally arrive at company1/address/phone, but this is cumbersome
Using getElementsByTagName("phone") will receive *all* phone nodes, so
not only that of company1 but also of all managers.
I'd like to use something like get
getElement("/company1/address/phone").
I believe MSXML has something like this (getSingleNode?).
Is this also possible in Xerces-C?

Thanks,
Rene


 
Reply With Quote
 
 
 
Reply

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Can't access a particular site - why? jsmith Computer Support 23 11-10-2009 06:13 PM
how to connect to a particular access point among many with same SSID? shitcompton Wireless Networking 0 02-04-2009 08:21 AM
restrict file access to only one particular user who enters correct password in web rajbala.3399@gmail.com Java 0 11-23-2006 09:38 AM
I can't access a particular site. Anna Computer Support 6 03-06-2006 09:29 AM
Re: Can't access one particular site Cliff Brown Computer Support 1 07-29-2003 02:36 AM



Advertisments
 



1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57