Re: [xml] incremental xmlreader

On Thu, Jul 17, 2003 at 10:48:24AM +0200, Luca Padovani wrote:

is it possible to implement incremental parsing of an XML document using
the xmlreader interface? I mean, I have a chunk of XML document
available, I parse it with the reader interface until I get an error. As
soon as the following chunk of document is available I recover with the
reader interface from where parsing was interrupted... and so on. 

  If you get the parser up to an error, then it cannot recover [*], so no.
But the reader is based on the push parser. So it should be relatively
easy to keep the control of the input stream. But I would need to see
some pseudo (python) code so I get an idea of the kind of interface you


[*] basically a requirement of the XML spec !

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]