GitHub

StartElement

API reference for StartElement.

A start tag, with its attributes in document order. name is the qualified name as written. <br/> is a StartElement then an EndElement.

With positions=True, line and column locate the tag's < as an XmlError would. With namespaces="strict", namespace ("" for none) and local_name are the resolved name; attributes stay keyed as written, and xmlns declarations stay attributes. Otherwise these fields are None. The encoders ignore them.

Attributes

AttributeTypeDescription
namestr
attributesMapping[str, str] = field(default_factory=(dict[str, str]), hash=False)
lineint | None = None
columnint | None = None
namespacestr | None = None
local_namestr | None = None

Functions

__init__

__init__(name, attributes=dict[str, str](), line=None, column=None, namespace=None, local_name=None) -> None
ParameterTypeDescription
namestr
attributesMapping[str, str] = dict[str, str]()
lineint | None = None
columnint | None = None
namespacestr | None = None
local_namestr | None = None