Re: [xml] xmlWriter?

 > > which holds the same problem that dom is rather memory consuptive. I'd
 > > like to use a sax interface, or something like the msxml counterpart
 > > to the xmlreader, the xmlwriter. Is there any support in libxml2 to
 > > let me do this? any ideas on how to work around this problem if there
 > > isn't ?

I am note sure to understand the reference to sax interface (what is the
meaning of sax for writing xml) and I am not familiar with msxml xmlwriter
- but there is missing the more important information:

for both methods what is the non dom input structure you have in mind?


Sax defines a push api/interface, on one side the parser pushes xml content to 
you, and on the other side you stick handlers for the content.

You can also use the sax api from the other side tho, you push xml content you 
want to have serialized , and on the other side there's a 
library/implementation that handles the content by writing it out to 

This has been done in other places before, look at apache cocoon serializers 
for example, that thing uses sax for everything and anything :)

Personally I'd rather have an xmlWriter interface tho, in the name of 
consistency. Cause there already is the xmlReader interface :)

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