Module Expr Str Import alias ImportFrom alias FunctionDef arguments args NameParam defaults body Expr Str Assign NameStore Call AttributeLoad AttributeLoad AttributeLoad NameLoad attr attr attr NameLoad Return Call NameLoad NameLoad decorator_list FunctionDef arguments args NameParam defaults body Expr Str Assign NameStore AttributeLoad NameLoad attr While BoolOpAnd NameLoad CompareEq AttributeLoad NameLoad attr AttributeLoad AttributeLoad AttributeLoad AttributeLoad NameLoad attr attr attr attr UnaryOpNot Call AttributeLoad AttributeLoad NameLoad attr attr body Assign NameStore AttributeLoad NameLoad attr If UnaryOpNot NameLoad body Return NameLoad If BoolOpOr CompareEq AttributeLoad NameLoad attr AttributeLoad AttributeLoad AttributeLoad AttributeLoad NameLoad attr attr attr attr CompareEq AttributeLoad NameLoad attr AttributeLoad AttributeLoad AttributeLoad AttributeLoad NameLoad attr attr attr attr body Assign NameStore AttributeLoad NameLoad attr If Call AttributeLoad NameLoad attr body Assign NameStore Call NameLoad NameLoad Return NameLoad Assign NameStore Call NameLoad NameLoad While NameLoad body If CompareEq AttributeLoad NameLoad attr AttributeLoad AttributeLoad AttributeLoad AttributeLoad NameLoad attr attr attr attr body Assign NameStore Dict If Call AttributeLoad NameLoad attr body Assign NameStore AttributeLoad NameLoad attr For NameStore Call NameLoad Num AttributeLoad NameLoad attr body Assign NameStore Call AttributeLoad NameLoad attr NameLoad Assign SubscriptStore NameLoad Index AttributeLoad NameLoad attr AttributeLoad NameLoad attr Expr Call AttributeLoad SubscriptLoad NameLoad Index AttributeLoad NameLoad attr attr Dict Str Str NameLoad Call NameLoad NameLoad Assign NameStore AttributeLoad NameLoad attr Return Call NameLoad NameLoad decorator_list If CompareEq NameLoad Str body Import alias Import alias TryExcept body Assign NameStore SubscriptLoad AttributeLoad NameLoad attr Index Num Assign NameStore Call AttributeLoad Call NameLoad NameLoad Str attr handlers ExceptHandler type NameLoad body Assign NameStore Call AttributeLoad AttributeLoad NameLoad attr attr Assign NameStore Call NameLoad NameLoad Print Call AttributeLoad NameLoad attr NameLoad keyword Num
N/A N/A 
xmlparse.py

Functions to convert XML into a python data structure

Original code from:
    http://nonplatonic.com/ben.php?title=python_xml_to_dict_bow_to_my_recursive_g&more=1&c=1&tb=1&pb=1
Modified by:
    Dave Eddy <dave@daveeddy.com>
        - Cleaned up whitespace errors
        - Added support for attributes
 N/A xml.dom.minidom collections defaultdict xmltodict N/A N/A xmlstring N/A N/A N/A 
    Convert an XML string into a dictionary

    @param	xmlstring	{string}	The XML string

    @return	{dict}	The resultant object
     N/A doc N/A N/A N/A N/A xml dom minidom parseString xmlstring N/A N/A _elementtodict doc N/A _elementtodict N/A N/A parent N/A N/A N/A 
    [Private function]

    Recursively search an XML element and construct a dictionary

    @param	element	{Node.ELEMENT_NODE}	The node to search

    @return	{dict}	The resultant object
     N/A child N/A parent firstChild N/A N/A child N/A N/A child nodeType N/A N/A N/A N/A xml dom minidom Node TEXT_NODE N/A N/A N/A N/A child data strip N/A N/A child N/A child nextSibling N/A N/A child N/A N/A None N/A N/A N/A N/A child nodeType N/A N/A N/A N/A xml dom minidom Node TEXT_NODE N/A N/A child nodeType N/A N/A N/A N/A xml dom minidom Node CDATA_SECTION_NODE N/A N/A value N/A child nodeValue N/A N/A N/A value isdigit N/A N/A value N/A int value N/A value N/A d N/A defaultdict list N/A child N/A N/A N/A N/A child nodeType N/A N/A N/A N/A xml dom minidom Node ELEMENT_NODE N/A N/A attr_dict N/A N/A N/A N/A child hasAttributes N/A N/A attrs N/A child attributes N/A i N/A range 0 N/A attrs length N/A N/A _attr N/A N/A attrs item i N/A N/A attr_dict N/A N/A _attr name N/A _attr value N/A N/A N/A N/A d N/A N/A child tagName append N/A attr child attr_dict N/A _elementtodict child N/A child N/A child nextSibling N/A N/A dict d N/A N/A N/A __name__ __main__ N/A N/A json N/A sys N/A N/A N/A xml_file N/A N/A sys argv N/A 1 N/A s N/A N/A N/A open xml_file r read N/A N/A N/A IndexError N/A N/A s N/A N/A N/A sys stdin read N/A d N/A xmltodict s N/A N/A N/A json dumps d indent 4