U
U
un1t2013-11-10 12:25:41
C++ / C#
un1t, 2013-11-10 12:25:41

Prompt XML parser for C++ to parse large files (1Gb+)

It is necessary that the parser does not load the entire file into memory, but reads it gradually. The more standard the library, the better. Those. if there is something like that in the standard STL or Boost libraries, then it’s generally ideal, if not, then maybe some more or less standard libraries for Linux can do it. And still must work quickly.

Answer the question

In order to leave comments, you need to log in

5 answer(s)
M
mejedi, 2013-11-10
@mejedi

Any SAX parser will do.

B
becks, 2013-11-10
@becks

Search for a SAX parser. Xerces, expat comes to mind, but there are many.

B
Biga, 2013-11-10
@Biga

There is also libxml2 in C, it can SAX. Pretty standard for Linux. I don't know about speed.

D
Dmitry, 2013-11-10
@deemytch

It strongly depends on the task.
If the goal is to parse everything and then poke around for a long time, then of course, either of the SAX type, the most common option is libxml2.
If the goal is to find something specific, then the fastest imho is line-by-line processing with regular expressions.

I
Ivaneo, 2013-11-11
@Ivaneo

Maybe pugixml will work for you.

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question