[XML-SIG] List of publicly usable modules
Martin v. Loewis
martin@v.loewis.de
10 May 2002 18:50:26 +0200
Andrew Kuchling <akuchlin@mems-exchange.org> writes:
> \item[\module{dom.TreeWalker}]
> Provides the \class{TreeWalker} class for multidirectional iteration
> over nodes.
This is an implementation detail - use createTreeWalker on the
document instead.
> \item[\module{dom.ext.Printer}]
> Classes to print XML from a DOM tree.
The usual interface is dom.ext.{Pretty}Print, although people may want
to use the Printer class directly to subclass it.
> \item[\module{dom.ext.XHtmlPrinter}]
> Classes for printing an HTML DOM tree as XHTML.
Likewise: you normally use dom.ext.XHtmlPrettyPrint.
> \item[\module{xml.parsers.xmlproc}]
> A validating XML parser.
Of the many modules in this package, few are public entry points
only. I think Lars-Marius could produce a list.
> \item[\module{sax.drivers}]
> SAX1 drivers for various parsers: \module{htmllib},
> LT, Expat, \module{sgmllib}, \module{xmllib}, xmlproc,
> and XML-Toolkit.
These are not "directly" public: use xml.sax.make_parser instead - but
you do need to know the module names.
> \item[\module{sax.drivers2}]
> SAX2 drivers for various parsers: \module{htmllib}, Java SAX parsers
> (for Jython), Expat, \module{sgmllib}, xmlproc.
Likewise.
> \item[\module{sax.handler}]
> Contains the core SAX2 handler classes \class{ContentHandler},
> \class{DTDHandler}, \class{EntityResolver},
> and \class{ErrorHandler}.
Also contains symbolic names for the features and properties.
> \item[\module{sax.saxexts}]
> SAX1 extensions. This contains various factory classes that create
> parser objects, and the \function{make_parser()} function.
make_parser is available through xml.sax (as such, it is also
available in Python 2, even though saxexts isn't). Use this only if
you need to make a SAX1 parser (could also use a Factory instead)
> \item[\module{sax.sax2exts}]
> SAX2 extensions. Like its SAX1 counterpart, this module contains
> various factory classes that create parser objects, and the
> \function{make_parser()} function.
Likewise, but never use this make_parser - instead, the various
Factory singletons are the public API here, and their make_parser
methods.
> \item[\module{xml.utils.characters}]
> Contains the legal XML character ranges as specified in the XML 1.0
> Recommendation, and regular expressions that match various
> XML tokens.
This is probably of interest only to authors of parsers, and DOM
implementations.
> \item[\module{xml.xpath}]
> An XPath parser and evaluator.
>
> \item[\module{xml.xslt}]
> An implementation of the XSLT transformation language.
> % XXX do the FourThought guys want a credit in the text here?
Yes. This code is work-in-progress (awaiting a merger from the next
4Suite release) - the agreement is that the names "4XPath" and "4XSLT"
get prominent mentioning where appropriate.
Regards,
Martin