falcong / pugixml

Automatically exported from code.google.com/p/pugixml
0 stars 0 forks source link

libcurl with pugixml #118

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
Use this request type if there is something you need to do with pugixml and
you don't know how.

What do you need to do with pugixml? Please provide a description of the
problem along with sample usage scenario.

I am using libcurl to fetch xml content through a http:// request. the 
writefunction in libcurl, returns entire XML content in 2-3 chunks, do all 
load_buffer* functions expect entire XML content before being called or is it 
possible to begin loading in chunks?

Thanks 

Original issue reported on code.google.com by devesh...@gmail.com on 22 Jul 2011 at 9:38

GoogleCodeExporter commented 9 years ago
It's impossible to load XML document in chunks; you'll have to wait for all 
content to arrive and store it in a single contiguous buffer before calling 
load_buffer.

Alternatively, if libcurl provides a C++ stream, you can load a document from 
it using load() function; pugixml will internally read all data from the stream 
to a contiguous buffer. If you go that way, make sure to use the trunk version 
instead of 1.0, since 1.0 does not support non-seekable streams (any HTTP 
stream is unlikely to support seeks).

Original comment by arseny.k...@gmail.com on 22 Jul 2011 at 9:55

GoogleCodeExporter commented 9 years ago
Thanks for a quick reply.

Original comment by devesh...@gmail.com on 22 Jul 2011 at 9:58