June 2000
Intermediate to advanced
556 pages
8h 45m
English
DocumentHandler is the main interface in SAX from a SAX application development perspective. It establishes handlers for start-tags, end-tags, processing instructions, character data, and so on. There are eight methods in the interface. The full stub interface looks like this.
CD-ROM reference=10005.txt class DocumentHandler: def characters(self, ch, start, length): "Handle a character data event." pass def endDocument(self): "Handle an event for the end of a document." pass def endElement(self, name): "Handle an event for the end of an element." pass def ignorableWhitespace(self, ch, start, length): "Handle an event for ignorable whitespace in element content." pass def processingInstruction(self, target, ...
Read now
Unlock full access