DOM and SAX have a few impedence matches at this time. You really can't
write a DOM builder that will capture everything SAX delivers, even when
the DOM is supposed to be able to present that information. You may want to
consider using a parser which builds a DOM directly, and thus is able to
use non-portable methods to construct that information, rather than going
through SAX.

The DOM's current approach to DocType is that you're expected to create the
DocumentType node via  DOMImplementaiton.createDocumentType(), then use
that as an argument to DOMImplementation.createDocument() (along with the
name and namespace of the root element). This is a slightly unnatural
sequence for parsers; DOM Level 3 is considering alternatives.

The DOM has no portable mechanism for populating the DocumentType. DOM
Level 3's Abstract Schema chapter -- specifically the Schema Editing APIs
-- will close that gap, for those DOMs which implement these APIs. (They'll
be optional.)




---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to