Beginners question with xerces DOM

K

kzawah

Hi, I am trying to quickly use xerces to parse some simple config
files. I have used SAX a bit before but this is my first day working
with DOM.

Ive looked at the docs, and downloaded some samples from the web, the
web sample is creating an XML writer dom implementation with:
pImplement =
DOMImplementationRegistry::getDOMImplementation(XercesString("LS"));
The xerces docs for the function say:
DOMImplementationRegistry::getDOMImplementation(const XMLCh * features
)
where features might be something like "XML 1.0 Traversal 2.0"

Whats "features" do I specify for a reader? Actually thats not my
question. A far better question would be where in the docs is the list
of the available or provided DOM implementations and the features we
need to specify to get them.

Thanks a lot
Kurt
 
M

Martin Honnen

Whats "features" do I specify for a reader? Actually thats not my
question. A far better question would be where in the docs is the list
of the available or provided DOM implementations and the features we
need to specify to get them.

Xerces tries to implement the W3C DOM so feature strings can be found in
the W3C DOM specifications, for instance here
<http://www.w3.org/TR/DOM-Level-3-Core/core.html#DOMFeatures>
<http://www.w3.org/TR/DOM-Level-3-LS/load-save.html#LS-DOMImplementation>
There are three different levels of the W3C DOM and there are various
modules. Finding a complete list of features strings often requires to
check all those specifications for the different modules. However nearly
all Level 2 features are listed here
<http://www.w3.org/TR/DOM-Level-2-Core/introduction.html#ID-Conformance>

Are you aware that there is a Xerces-C user mailing list here
<http://marc.theaimsgroup.com/?l=xerces-c-users>
? There you might find more expertise on using Xerces-C.
 
K

Kza

Thanks a lot, got everything working now. Next step might be helping
xerces out with their docs :p Some examples and header files would be
nice, and mentioning "XML 1.0 Traversal 2.0" as a possible feature
rather than "LS" which is what 90% of the people coming in looking for
a quick answer are looking for. Gives me the feeling theres a religous
reason behind it though, as if its important to draw a line between
xerces and the w3c...

I think XML in general is still in the early days, like needing to be a
mechanic in order to drive a car, in the sense that one needs to know
more of the technical specs to USE a parser than hack one up from
scratch.

Still I look forward to more user friendly xml tools in the near future
:)

Thanks again.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
473,768
Messages
2,569,575
Members
45,053
Latest member
billing-software

Latest Threads

Top