ó ¿œ^c@s‘dZddlZddlmZddlmZmZdejfd„ƒYZe dkr�eƒZ e j eƒƒe j ej dƒndS( s— A simple demo that reads in an XML document and displays the number of elements and attributes as well as a tally of elements and attributes by name. iÿÿÿÿN(t defaultdict(t make_parserthandlert FancyCountercBs#eZd„Zd„Zd„ZRS(cCs4d|_d|_ttƒ|_ttƒ|_dS(Ni(t_elemst_attrsRtintt _elem_typest _attr_types(tself((s+/usr/lib64/python2.7/Demo/xml/elem_count.pyt__init__ s  cCse|jd7_|jt|ƒ7_|j|cd7s