Re: [xml] Simple question on going from xmlDocPtr to memory buffer



On Thu, Jul 07, 2005 at 09:40:30AM +0200, Alain Paschoud wrote:
Hi all,

I am new with XML, and wrote a program that should do next things:

1) Read and decode a file with DES (no XML functions here), put it in a
memory buffer.
2) Parse the XML which is in the memory buffer. Used : xmlParseMemory()

   xmlReadMemory is the new API, I suggest to use that one instead.

3) Modify elements. Used : xmlNodeListGetString() and xmlNodeSetContent()
4) "un"parse the xmlDocPtr to get XML ascii in memory
5) Crypt and write this buffer to a file (no XML here)

The problem is on the 4th step : I can't find a function doing the
opposite than xmlParseMemory(). I mean lead from xmlDocPtr type to a XML
in ascii in memory. I found it for writing directly to a file
(xmlSaveFile), but not in memory. Can someone help ?

  http://xmlsoft.org/html/libxml-tree.html#xmlDocDumpFormatMemory

which you can find easilly by using teh search engine for
"writing in memory" within the XML API domain ...

  http://xmlsoft.org/search.php?query=writing+in+memory&scope=XMLAPI&submit=Search+...

Daniel
-- 
Daniel Veillard      | Red Hat Desktop team http://redhat.com/
veillard redhat com  | libxml GNOME XML XSLT toolkit  http://xmlsoft.org/
http://veillard.com/ | Rpmfind RPM search engine http://rpmfind.net/



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