Re: [xml] Do xmlBuffers grow dynamically as needed?

On Mon, Aug 19, 2002 at 11:33:41AM +0200, Holger Rauch wrote:

I'm new to libxml2 and trying to extract a document fragment using
xmlNodeDump(). This function requires an xmlBufferPtr as one of its
arguments. Will calling xmlNodeDump() automatically grow a previously
xmlBufferCreate()ed xmlBuffer? If not, what are the alternatives?

  yes xmlBuffer(s) grow automatically as needed.
Alternative is to use an xmlOutputBufferPtr created with the callbacks needed
for your output and call xmlNodeDumpOutput() instead, this is useful
if you don't want the full document serialized in memory and stream
it out progressively.


Daniel Veillard      | Red Hat Network
veillard redhat com  | libxml GNOME XML XSLT toolkit | Rpmfind RPM search engine

[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]