[xml] Is there a way using SAX2 IO Parser to ignore chars before / after a "document"?



Hi.

I'm using the xmlCreateIOParserCtxt() and xmlSAXUserParseMemory()
methods to parse XML messages being received on a socket.

I have the program running, and am able to use the SAX2 callbacks to
parse complete XML messages, as long as they come in one at a time, and
without extraneous characters before or after them.

Is there a way to use the parser callbacks to "ignore" leading or
trailing characters between valid XML "documents"?

And, is there a way to handle two or more XML "documents" (i.e.
messages) within one read() (i.e. within one call to
xmlSAXUserParseMemory()?

Any ideas would be appreciated.

Chris Hesterman 




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