parser
– XML Parser Module¶
-
class
lazyxml.parser.
Parser
(**kw)¶ XML Parser
-
set_options
(**kw)¶ Set Parser options.
See also
kw
argument have the same meaning as inlazyxml.loads()
-
get_options
()¶ Get Parser options.
-
xml2dict
(content)¶ Convert xml content to dict.
Warning
DEPRECATED:
xml2dict()
is deprecated. Please usexml2object()
instead.Deprecated since version 1.2.
-
xml2object
(content)¶ Convert xml content to python object.
Parameters: content – xml content Return type: dict New in version 1.2.
-
xml_filter
(content)¶ Filter and preprocess xml content
Parameters: content – xml content Return type: str
-
guess_xml_encoding
(content)¶ Guess encoding from xml header declaration.
Parameters: content – xml content Return type: str or None
-
parse_full
(element)¶ Parse xml element include the node attributes.
Parameters: element – an Element
instanceReturn type: dict New in version 1.2.1.
-