def get_css_class_dict(node): """ Given an xml.dom.minidom.Node, returns a map from every "class" attribute from it to a list of nodes with this class. For example, for the document below: >>> doc = xml.dom.minidom.parseString( ... ''' ... ... ...
... ... ... ''') ...we will get this: >>> d = get_css_class_dict(doc) >>> d['a'] # doctest: +ELLIPSIS [, ] >>> d['b'] # doctest: +ELLIPSIS [] """ pass