xml.sax.xmlreader.IncrementalParser

class xml.sax.xmlreader.IncrementalParser In some cases, it is desirable not to parse an input source at once, but to feed chunks of the document as they get available. Note that the reader will normally not read the entire file, but read it in chunks as well; still parse() won’t return until the entire document is processed. So these interfaces should be used if the blocking behaviour of parse() is not desirable. When the parser is instantiated it is ready to begin accepting data from the f

xml.sax.xmlreader.InputSource.getByteStream()

InputSource.getByteStream() Get the byte stream for this input source. The getEncoding method will return the character encoding for this byte stream, or None if unknown.

xml.sax.xmlreader.InputSource

class xml.sax.xmlreader.InputSource(system_id=None) Encapsulation of the information needed by the XMLReader to read entities. This class may include information about the public identifier, system identifier, byte stream (possibly with character encoding information) and/or the character stream of an entity. Applications will create objects of this class for use in the XMLReader.parse() method and for returning from EntityResolver.resolveEntity. An InputSource belongs to the application, th

xml.sax.xmlreader.IncrementalParser.reset()

IncrementalParser.reset() This method is called after close has been called to reset the parser so that it is ready to parse new documents. The results of calling parse or feed after close without calling reset are undefined.

xml.sax.xmlreader.IncrementalParser.feed()

IncrementalParser.feed(data) Process a chunk of data.

xml.sax.xmlreader.IncrementalParser.close()

IncrementalParser.close() Assume the end of the document. That will check well-formedness conditions that can be checked only at the end, invoke handlers, and may clean up resources allocated during parsing.

xml.sax.xmlreader.Attributes.getType()

Attributes.getType(name) Returns the type of the attribute name, which is normally 'CDATA'.

xml.sax.xmlreader.AttributesImpl

class xml.sax.xmlreader.AttributesImpl(attrs) This is an implementation of the Attributes interface (see section The Attributes Interface). This is a dictionary-like object which represents the element attributes in a startElement() call. In addition to the most useful dictionary operations, it supports a number of other methods as described by the interface. Objects of this class should be instantiated by readers; attrs must be a dictionary-like object containing a mapping from attribute na

xml.sax.xmlreader.AttributesNS.getNameByQName()

AttributesNS.getNameByQName(name) Return the (namespace, localname) pair for a qualified name.

xml.sax.xmlreader.AttributesNS.getQNames()

AttributesNS.getQNames() Return the qualified names of all attributes.