[XML-SIG] need a bit clarification

Fred L. Drake, Jr. fdrake@acm.org
Fri, 31 Mar 2000 13:18:42 -0500 (EST)

oliver writes:
 > - From XML-howto, it seems xmllib.py can do both DOM/SAX parsing, is it
 >   true? and this module does come with python 1.52 distribution, so does
 >   it mean the "official entry" I should take?

  xmllib is "SAX-like"; there isn't anything DOM-like about it.  It
will be deprecated in future releases of Python.  The interface does
not lend itself to full support for XML, and it is not a compliant
parser.  There is no intention to maintain it further.

 > - New distribution on XML-SIG homepage include a interface of Expad
 >   parser, the primary advantage is the performance side, is this
 >   understanding correct?

  This will become the standard parser as of Python 1.6.  Both SAX and
DOM will be offered with this parser, and SAX using Expat will be part
of the standard library in Python 1.6.

 > - xmlproc is said written in python and implement only SAX, my guess is it
 >   has better integration. Does it have plan for DOM?

  A DOM object can be built from the SAX event stream, so the DOM will
be available with any SAX-supporting parser.

 > My other questions is: what the focus of current development effort, if I
 > were to start a project doing processing (simple parse and action), would
 > it be sufficient to just stay with xmllib? Any long term concerns?

  Perhaps the best approach would be to require the PyXML package now
and use the SAX interface.  The additional package requirement will
disappear with Python 1.6 if you restrict yourself to SAX.


Fred L. Drake, Jr.	  <fdrake at acm.org>
Corporation for National Research Initiatives