# lxml.ElementInclude module

Limited XInclude support for the ElementTree package.

While lxml.etree has full support for XInclude (see etree.ElementTree.xinclude()), this module provides a simpler, pure Python, ElementTree compatible implementation that supports a simple form of custom URL resolvers.

exception lxml.ElementInclude.FatalIncludeError

  Bases: `LxmlSyntaxError`

  add_note(note, /)

    Add a note to the exception

  with_traceback(tb, /)

    Set self.__traceback__ to tb and return self.

  _metadata

    exception private metadata

  args
  end_lineno

    exception end lineno

  end_offset

    exception end offset

  filename

    exception filename

  lineno

    exception lineno

  msg

    exception msg

  offset

    exception offset

  print_file_and_line

    exception print_file_and_line

  text

    exception text

exception lxml.ElementInclude.LimitedRecursiveIncludeError

  Bases: `FatalIncludeError`

  add_note(note, /)

    Add a note to the exception

  with_traceback(tb, /)

    Set self.__traceback__ to tb and return self.

  _metadata

    exception private metadata

  args
  end_lineno

    exception end lineno

  end_offset

    exception end offset

  filename

    exception filename

  lineno

    exception lineno

  msg

    exception msg

  offset

    exception offset

  print_file_and_line

    exception print_file_and_line

  text

    exception text

lxml.ElementInclude._include(elem, loader=None, base_url=None, max_depth=6, _parent_hrefs=None)

lxml.ElementInclude._lxml_default_loader(href, parse, encoding=None, parser=None)

lxml.ElementInclude._wrap_et_loader(loader)

lxml.ElementInclude.default_loader(href, parse, encoding=None)

lxml.ElementInclude.include(elem, loader=None, base_url=None, max_depth=6)