[frames] | no frames]

[ Module Hierarchy | Class Hierarchy ]

# Class Hierarchy

- xml.sax.handler.ContentHandler: Interface for receiving logical document content events.
  - lxml.sax.ElementTreeContentHandler: Build an lxml ElementTree from SAX events.
- lxml.etree.ErrorDomains: Libxml2 error domains Libxml2 error domains
- lxml.etree.ErrorLevels: Libxml2 error levels Libxml2 error levels
- lxml.etree.ErrorTypes: Libxml2 error types Libxml2 error types
- lxml.tests.common_imports.LargeFileLike
- doctest.OutputChecker: A class used to check the whether the actual output from a doctest example matches the expected output.
  - lxml.doctestcompare.LXMLOutputChecker
    - lxml.doctestcompare.LHTMLOutputChecker
- lxml.etree.RelaxNGErrorTypes: Libxml2 RelaxNG error types Libxml2 RelaxNG error types
- lxml.tests.common_imports.SillyFileLike
- object: The most base type
  - exceptions.BaseException: Common base class for all exceptions
    - exceptions.Exception: Common base class for all non-exit exceptions.
      - lxml.etree.Error
        - lxml.etree.LxmlError: this one.
          - lxml.etree.C14NError: Error during C14N serialisation.
          - lxml.etree.DTDError: Base class for DTD errors.
            - lxml.etree.DTDParseError: Error while parsing a DTD.
            - lxml.etree.DTDValidateError: Error while validating an XML document with a DTD.
          - lxml.etree.DocumentInvalid: Validation error.
          - lxml.etree.LxmlRegistryError: Base class of lxml registry errors.
            - lxml.etree.NamespaceRegistryError: Error registering a namespace extension.
          - lxml.etree.LxmlSyntaxError: Base class for all syntax errors.
            - lxml.ElementInclude.FatalIncludeError
            - lxml.etree.ParseError: Syntax error while parsing an XML document.
              - lxml.etree.XMLSyntaxError: Syntax error while parsing an XML document.
            - lxml.etree.XPathSyntaxError
          - lxml.etree.ParserError: Internal lxml parser error.
          - lxml.etree.RelaxNGError: Base class for RelaxNG errors.
            - lxml.etree.RelaxNGParseError: Error while parsing an XML document as RelaxNG.
            - lxml.etree.RelaxNGValidateError: Error while validating an XML document with a RelaxNG schema.
          - lxml.sax.SaxError: General SAX error.
          - lxml.etree.SchematronError: Base class of all Schematron errors.
            - lxml.etree.SchematronParseError: Error while parsing an XML document as Schematron schema.
            - lxml.etree.SchematronValidateError: Error while validating an XML document with a Schematron schema.
          - lxml.etree.XIncludeError: Error during XInclude processing.
          - lxml.etree.XMLSchemaError: Base class of all XML Schema errors
            - lxml.etree.XMLSchemaParseError: Error while parsing an XML document as XML Schema.
            - lxml.etree.XMLSchemaValidateError: Error while validating an XML document with an XML Schema.
          - lxml.etree.XPathError: Base class of all XPath errors.
            - lxml.etree.XPathEvalError: Error during XPath evaluation.
              - lxml.etree.XPathFunctionError: Internal error looking up an XPath extension function.
              - lxml.etree.XPathResultError: Error handling an XPath result.
            - lxml.etree.XPathSyntaxError
          - lxml.etree.XSLTError: Base class of all XSLT errors.
            - lxml.etree.XSLTApplyError: Error running an XSL transformation.
            - lxml.etree.XSLTExtensionError: Error registering an XSLT extension.
            - lxml.etree.XSLTParseError: Error parsing a stylesheet document.
            - lxml.etree.XSLTSaveError: Error serialising an XSLT result.
      - exceptions.StandardError: Base class for all standard Python exceptions that do not represent interpreter exiting.
        - exceptions.AssertionError: Assertion failed.
        - exceptions.LookupError: Base class for lookup errors.
          - lxml.html.formfill.FormNotFound: Raised when no form can be found
        - exceptions.RuntimeError: Unspecified run-time error.
          - lxml.cssselect.ExpressionError
        - exceptions.SyntaxError: Invalid syntax.
          - lxml.etree.LxmlSyntaxError: Base class for all syntax errors.
            - lxml.ElementInclude.FatalIncludeError
            - lxml.etree.ParseError: Syntax error while parsing an XML document.
              - lxml.etree.XMLSyntaxError: Syntax error while parsing an XML document.
            - lxml.etree.XPathSyntaxError
          - elementtree.ElementTree.ParseError
          - lxml.cssselect.SelectorSyntaxError
  - lxml.html.clean.Cleaner: Instances cleans the document of each of the possible offending elements.
  - lxml.html.formfill.DefaultErrorCreator
  - lxml.etree.DocInfo: Document information provided by parser and DTD.
  - elementtree.ElementTree.Element
  - lxml.etree.ElementClassLookup: ElementClassLookup(self)
    - lxml.etree.ElementDefaultClassLookup: ElementDefaultClassLookup(self, element=None, comment=None, pi=None, entity=None) Element class lookup scheme that always returns the default Element class.
    - lxml.etree.FallbackElementClassLookup: FallbackElementClassLookup(self, fallback=None)
      - lxml.etree.AttributeBasedElementClassLookup: AttributeBasedElementClassLookup(self, attribute_name, class_mapping, fallback=None) Checks an attribute of an Element and looks up the value in a class dictionary.
      - lxml.etree.CustomElementClassLookup: CustomElementClassLookup(self, fallback=None) Element class lookup based on a subclass method.
      - lxml.etree.ElementNamespaceClassLookup: ElementNamespaceClassLookup(self, fallback=None)
      - lxml.etree.ParserBasedElementClassLookup: ParserBasedElementClassLookup(self, fallback=None) Element class lookup based on the XML parser.
      - lxml.pyclasslookup.PythonElementClassLookup: PythonElementClassLookup(self, fallback=None) Element class lookup based on a subclass method.
    - lxml.objectify.ObjectifyElementClassLookup: ObjectifyElementClassLookup(self, tree_class=None, empty_data_class=None) Element class lookup method that uses the objectify classes.
  - lxml.builder.ElementMaker: Element generator factory.
  - lxml.objectify.ElementMaker: ElementMaker(self, namespace=None, nsmap=None, annotate=True, makeelement=None)
  - lxml.etree.ElementTextIterator: ElementTextIterator(self, element, tag=None, with_tail=True) Iterates over the text content of a subtree.
  - elementtree.ElementTree.ElementTree
  - lxml.sax.ElementTreeContentHandler: Build an lxml ElementTree from SAX events.
  - lxml.sax.ElementTreeProducer: Produces SAX events for an element and children.
  - lxml.objectify.ObjectPath: ObjectPath(path) Immutable object that represents a compiled object path.
  - lxml.objectify.PyType: PyType(self, name, type_check, type_class, stringify=None) User defined type.
  - lxml.etree.QName: QName(text_or_uri, tag=None)
  - elementtree.ElementTree.QName
  - lxml.etree.Resolver: This is the base class of all resolvers.
  - unittest.TestCase: A class whose instances are single test cases.
    - lxml.tests.common_imports.HelperTestCase
      - lxml.tests.test_css.CSSTestCase
      - lxml.tests.test_classlookup.ClassLookupTestCase: Test cases for different Element class lookup mechanisms.
      - lxml.tests.test_etree.ETreeC14NTestCase
      - lxml.tests.test_dtd.ETreeDtdTestCase
      - lxml.tests.test_xpathevaluator.ETreeETXPathClassTestCase: Tests for the ETXPath class
      - lxml.tests.test_nsclasses.ETreeNamespaceClassesTestCase
      - lxml.tests.test_etree.ETreeOnlyTestCase: Tests only for etree, not ElementTree
      - lxml.tests.test_relaxng.ETreeRelaxNGTestCase
      - lxml.tests.test_sax.ETreeSaxTestCase
      - lxml.tests.test_schematron.ETreeSchematronTestCase
      - lxml.tests.test_elementtree.ETreeTestCaseBase
        - lxml.tests.test_elementtree.ETreeTestCase
        - lxml.tests.test_elementtree.ElementTreeTestCase
      - lxml.tests.test_xmlschema.ETreeXMLSchemaTestCase
      - lxml.tests.test_xpathevaluator.ETreeXPathClassTestCase: Tests for the XPath class
      - lxml.tests.test_xpathevaluator.ETreeXPathTestCase: XPath tests etree
      - lxml.tests.test_xslt.ETreeXSLTTestCase: XPath tests etree
      - lxml.tests.test_errors.ErrorTestCase
      - lxml.tests.test_htmlparser.HtmlParserTestCase: HTML parser test cases
      - lxml.tests.test_io.IOTestCaseBase: (c)ElementTree compatibility for IO functions/methods
        - lxml.tests.test_io.ETreeIOTestCase
        - lxml.tests.test_io.ElementTreeIOTestCase
      - lxml.tests.test_objectify.ObjectifyTestCase: Test cases for lxml.objectify
      - lxml.tests.test_pyclasslookup.PyClassLookupTestCase: Test cases for the lxml.pyclasslookup class lookup mechanism.
      - lxml.tests.test_unicode.UnicodeTestCase
      - lxml.tests.test_etree.XIncludeTestCase
        - lxml.tests.test_etree.ETreeXIncludeTestCase
        - lxml.tests.test_etree.ElementIncludeTestCase
  - elementtree.ElementTree.TreeBuilder
  - lxml.etree.XInclude: XInclude(self) XInclude processor.
  - elementtree.ElementTree.XMLParser
  - lxml.etree.XSLT: XSLT(self, xslt_input, extensions=None, regexp=True, access_control=None)
  - lxml.etree.XSLTAccessControl: XSLTAccessControl(self, read_file=True, write_file=True, create_dir=True, read_network=True, write_network=True)
  - lxml.etree._BaseErrorLog
    - lxml.etree.PyErrorLog: PyErrorLog(self, logger_name=None) A global error log that connects to the Python stdlib logging package.
  - lxml.etree._BaseParser
    - lxml.etree._FeedParser
      - lxml.etree.HTMLParser: HTMLParser(self, recover=True, no_network=True, remove_blank_text=False, compact=True, remove_comments=False, remove_pis=False, target=None, encoding=None, schema=None) The HTML parser.
      - lxml.etree.XMLParser: XMLParser(self, attribute_defaults=False, dtd_validation=False, load_dtd=False, no_network=True, ns_clean=False, recover=False, remove_blank_text=False, compact=True, resolve_entities=True, remove_comments=False, remove_pis=False, target=None, encoding=None, schema=None) The XML parser.
        - lxml.etree.ETCompatXMLParser: ETCompatXMLParser(self, attribute_defaults=False, dtd_validation=False, load_dtd=False, no_network=True, ns_clean=False, recover=False, remove_blank_text=False, compact=True, resolve_entities=True, remove_comments=True, remove_pis=True, target=None, encoding=None, schema=None) An XML parser with an ElementTree compatible default setup.
    - lxml.etree.iterparse: iterparse(self, source, events=("end",), tag=None, attribute_defaults=False, dtd_validation=False, load_dtd=False, no_network=True, remove_blank_text=False, remove_comments=False, remove_pis=False, encoding=None, html=False, schema=None) Incremental parser.
  - lxml.etree._Element: Element class.
    - lxml.etree.ElementBase: All custom Element classes must inherit from this one.
      - lxml.objectify.ObjectifiedElement: Main XML Element class.
        - lxml.objectify.ObjectifiedDataElement: This is the base class for all data type Elements.
          - lxml.objectify.BoolElement: Boolean type base on string values: 'true' or 'false'.
          - lxml.objectify.NoneElement
          - lxml.objectify.NumberElement
            - lxml.objectify.FloatElement
            - lxml.objectify.IntElement
            - lxml.objectify.LongElement
          - lxml.objectify.StringElement: String data class.
      - lxml.tests.test_nsclasses.ETreeNamespaceClassesTestCase.bluff_class
      - lxml.tests.test_nsclasses.ETreeNamespaceClassesTestCase.default_class
      - lxml.tests.test_nsclasses.ETreeNamespaceClassesTestCase.maeh_class
    - lxml.etree.__ContentOnlyElement
      - lxml.etree._Comment
        - lxml.etree.CommentBase: All custom Comment classes must inherit from this one.
      - lxml.etree._Entity
        - lxml.etree.EntityBase: All custom Entity classes must inherit from this one.
      - lxml.etree._ProcessingInstruction
        - lxml.etree.PIBase: All custom Processing Instruction classes must inherit from this one.
  - lxml.etree._ElementTagMatcher
    - lxml.etree.ElementDepthFirstIterator: ElementDepthFirstIterator(self, node, tag=None, inclusive=True) Iterates over an element and its sub-elements in document order (depth first pre-order).
    - lxml.etree._ElementIterator
      - lxml.etree.AncestorsIterator: AncestorsIterator(self, node, tag=None) Iterates over the ancestors of an element (from parent to parent).
      - lxml.etree.ElementChildIterator: ElementChildIterator(self, node, tag=None, reversed=False) Iterates over the children of an element.
      - lxml.etree.SiblingsIterator: SiblingsIterator(self, node, tag=None, preceding=False) Iterates over the siblings of an element.
  - lxml.etree._SaxParserTarget
    - lxml.etree.TreeBuilder: TreeBuilder(self, element_factory=None, parser=None) Parser target that builds a tree.
  - lxml.etree._Validator: Base class for XML validators.
    - lxml.etree.DTD: DTD(self, file=None, external_id=None) A DTD validator.
    - lxml.etree.RelaxNG: RelaxNG(self, etree=None, file=None) Turn a document into a Relax NG validator.
    - lxml.etree.Schematron: Schematron(self, etree=None, file=None) A Schematron validator.
    - lxml.etree.XMLSchema: XMLSchema(self, etree=None, file=None) Turn a document into an XML Schema validator.
  - lxml.etree._XPathEvaluatorBase
    - lxml.etree.XPath: XPath(self, path, namespaces=None, extensions=None, regexp=True) A compiled XPath expression that can be called on Elements and ElementTrees.
      - lxml.cssselect.CSSSelector: A CSS selector.
      - lxml.etree.ETXPath: ETXPath(self, path, extensions=None, regexp=True) Special XPath class that supports the ElementTree {uri} notation for namespaces.
    - lxml.etree.XPathElementEvaluator: XPathElementEvaluator(self, element, namespaces=None, extensions=None, regexp=True) Create an XPath evaluator for an element.
      - lxml.etree.XPathDocumentEvaluator: XPathDocumentEvaluator(self, etree, namespaces=None, extensions=None, regexp=True) Create an XPath evaluator for an ElementTree.
  - lxml.etree.iterwalk: iterwalk(self, element_or_tree, events=("end",), tag=None)