What is the mechanism that Xerces C++ follows for parsing a Stream?

G

Girish

Hello..

I need to understand how parsing of a file or a stream(XML data in
memory) takes place in Xerces C++. I am using SAX XMLReader and passing xml
input as a file path or a MemBufInputSource object. In order to create a
MemBufInputSource object I need to have the entire data in memory(as given
in MemParse sample). This may create problems if I have a large amount of
data, say in hundreds of MB.

In case of files, does the parser read the entire file into memory and then
parse it? or Does it read it in chunks?
If it does it in chunks can we simulate the same for xml data in memory?
What are the things to be taken care of in this case?

The need to understand the mechanism arises from the requirement to
progressively parse xml data by loading small chunks into the memory.
Can somebody give me some pointers in this regard?

Thanking you in advance!

warm regards,
Girish
 

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,777
Messages
2,569,604
Members
45,235
Latest member
Top Crypto Podcasts_

Latest Threads

Top