Re: Memory Overhead

I forgot to add...

Regarding the whitespace text nodes; That's something the DOM doesn't
really have any choice about, since the XML Recommendation explicitly
requires that all whitespace be passed through to the application. Many XML
parsers have a "filtering" mode which allows applications to request that
whitespace-in-element-content be discarded; check yours to see if it has
that option.  Note that the parser can only recognize this case if you are
validating against a DTD or schema; if you don't do so, it has no way of
determining which whitespace is and isn't meaningful and must deliver it
all to avoid damaging the document.

DOM Level 3's Load/Save chapter is considering permitting such a filter.  I
believe we discussed the possibility of also allowing user-written filters,
so you could plug in logic to discard other unwanted information with or
without a DTD's advice.

______________________________________
Joe Kesselman  / IBM Research

Received on Monday, 10 September 2001 11:45:47 UTC