C++ XML parsers?

L

Laurens

Hi,


Is there any good open-source C++ XML parser library that isn't as huge as
Xerces? The Xerces DLL is about 2.4 Mb in size, which is far too big for my
application. (It doesn't seem to be possible to link Xerces statically.)

The parser doesn't need to do DTD/Schema validation, but it should be able
to expand entities. I also need a DOM to navigate the document. XPath
querying would be nice, but is not essential.

Any ideas?


Thanks
-Laurens
 
B

Bernd Petrovitsch

Is there any good open-source C++ XML parser library that isn't as huge as
Xerces? The Xerces DLL is about 2.4 Mb in size, which is far too big for my
application. (It doesn't seem to be possible to link Xerces statically.)

There are also libxml2 and expat in the C/C++-world.

Bernd
 
R

Roberto Nunnari

Hi.

If you're not interested in validating, watch out for NunniMCAX,
my C parser that will come out soon. About 60KB in size..

see NunniMJAX at http://nunnimjax.nunnisoft.ch
...that's its java brother that was just released last week.

It's Open Source!

Best regards.
 
P

Patrick TJ McPhee

% The parser doesn't need to do DTD/Schema validation, but it should be able
% to expand entities. I also need a DOM to navigate the document. XPath
% querying would be nice, but is not essential.

There are a few options, which I will try to enumerate. You'll
have to search for urls. You don't mention the platform. I'll assume
win32 since you mention a DLL.

libxml2 -- full-featured (various types of validation, Dom-ish and SAX-ish
APIs, xPath, a related xslt library, and on and on), but almost
as large as xerces in the win32 binary distribution. You can
recompile with features turned off, so you might get it down to
a size you can live with.
expat -- SAX-ish API only, non-validating. less than 100k
rxp -- DTD validation. Name space support. I'm not sure how you'd
describe the API. About 300k -- I'm not sure if there's an
NT port, but how hard could it be?
tinyxml -- less than 100k. DOM-ish API. I've never tried this -- the
readme said it didn't use DTDs (so probably not suitable for
your purposes).

I'm pretty sure I've forgotten one. The first three are C and the last is
C++.
 

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,995
Messages
2,570,233
Members
46,820
Latest member
GilbertoA5

Latest Threads

Top