>I have a question regarding the "XMLCh*" and "Attributes" instances passed
>to ContentHandler::startElement(). How long are these references
guaranteed
>to be valid? Can I store them off (as is) until
>ContentHandler::endDocument() is called?
In general, SAX parsers reserve the right to reuse their data buffers. Any
data passed into a SAX event handler must be explicitly copied into your
own storage if you want to retain it past the end of that event.
(The alternative would be for the parser to create new instances for
everything it passes in whether you ever use them or not, which would be
far less efficient than making you copy the ones you want to retain.)
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]