def getElement(self, node, name, nsuri=None, default=join):
nsmatch = self.nsUriMatch<EOL>ELEMENT_NODE = node.ELEMENT_NODE<EOL>for child in node.childNodes:<EOL><INDENT>if child.nodeType == ELEMENT_NODE:<EOL><INDENT>if ((child.localName == name or name is None) and<EOL>(nsuri is None or nsmatch(child.namespaceURI, nsuri))<EOL>):<EOL><INDENT>return child<EOL><DEDENT><DEDENT><DEDENT>if default is not join:<EOL><INDENT>return default<EOL><DEDENT>raise KeyError(name)<EOL>
Return the first child of node with a matching name and
           namespace uri, or the default if one is provided.