xml.sax
¶
Simple API for XML (SAX) implementation for Python.
This module provides an implementation of the SAX 2 interface; information about the Java version of the interface can be found at http://www.megginson.com/SAX/. The Python version of the interface is documented at <...>.
This package contains the following modules:
- handler – Base classes and constants which define the SAX 2 API for
- the ‘client-side’ of SAX for Python.
- saxutils – Implementation of the convenience classes commonly used to
- work with SAX.
- xmlreader – Base classes and constants which define the SAX 2 API for
- the parsers used with SAX for Python.
expatreader – Driver that allows use of the Expat parser with SAX.
Functions¶
make_parser ([parser_list]) |
Creates and returns a SAX parser. |
parse (source, handler[, errorHandler]) |
|
parseString (string, handler[, errorHandler]) |
Classes¶
ContentHandler () |
Interface for receiving logical document content events. |
ErrorHandler |
Basic interface for SAX error handlers. |
InputSource ([system_id]) |
Encapsulation of the information needed by the XMLReader to read entities. |
Exceptions¶
SAXException (msg[, exception]) |
Encapsulate an XML error or warning. |
SAXNotRecognizedException (msg[, exception]) |
Exception class for an unrecognized identifier. |
SAXNotSupportedException (msg[, exception]) |
Exception class for an unsupported operation. |
SAXParseException (msg, exception, locator) |
Encapsulate an XML parse error or warning. |
SAXReaderNotAvailable (msg[, exception]) |
Exception class for a missing driver. |