summaryrefslogtreecommitdiffstats
path: root/Lib/xml/dom
diff options
context:
space:
mode:
authorFred Drake <fdrake@acm.org>2001-11-30 22:21:58 (GMT)
committerFred Drake <fdrake@acm.org>2001-11-30 22:21:58 (GMT)
commit49a5d03ab4b0ec9397fa7f449cb28d07edd8860f (patch)
tree2a8a1e53b00b1b21ef0ebe034030382d6baab146 /Lib/xml/dom
parent381832ead56dba0499d8e795a46e87bf375c43a3 (diff)
downloadcpython-49a5d03ab4b0ec9397fa7f449cb28d07edd8860f.zip
cpython-49a5d03ab4b0ec9397fa7f449cb28d07edd8860f.tar.gz
cpython-49a5d03ab4b0ec9397fa7f449cb28d07edd8860f.tar.bz2
Synchronize with minidom from PyXML (revision 1.35).
Diffstat (limited to 'Lib/xml/dom')
-rw-r--r--Lib/xml/dom/minidom.py10
1 files changed, 5 insertions, 5 deletions
diff --git a/Lib/xml/dom/minidom.py b/Lib/xml/dom/minidom.py
index 510817e..5b26da7 100644
--- a/Lib/xml/dom/minidom.py
+++ b/Lib/xml/dom/minidom.py
@@ -18,7 +18,7 @@ import string
_string = string
del string
-from xml.dom import HierarchyRequestErr
+from xml.dom import HierarchyRequestErr, EMPTY_NAMESPACE
# localize the types, and allow support for Unicode values if available:
import types
@@ -329,7 +329,7 @@ class Attr(Node):
ownerElement = None
childNodeTypes = (Node.TEXT_NODE, Node.ENTITY_REFERENCE_NODE)
- def __init__(self, qName, namespaceURI="", localName=None, prefix=None):
+ def __init__(self, qName, namespaceURI=EMPTY_NAMESPACE, localName=None, prefix=None):
# skip setattr for performance
d = self.__dict__
d["localName"] = localName or qName
@@ -394,7 +394,7 @@ class NamedNodeMap:
def itemsNS(self):
L = []
for node in self._attrs.values():
- L.append(((node.URI, node.localName), node.value))
+ L.append(((node.namespaceURI, node.localName), node.value))
return L
def keys(self):
@@ -468,7 +468,7 @@ class Element(Node):
Node.COMMENT_NODE, Node.TEXT_NODE,
Node.CDATA_SECTION_NODE, Node.ENTITY_REFERENCE_NODE)
- def __init__(self, tagName, namespaceURI=None, prefix="",
+ def __init__(self, tagName, namespaceURI=EMPTY_NAMESPACE, prefix=None,
localName=None):
Node.__init__(self)
self.tagName = self.nodeName = tagName
@@ -754,7 +754,7 @@ def _nssplit(qualifiedName):
if len(fields) == 2:
return fields
elif len(fields) == 1:
- return ('', fields[0])
+ return (None, fields[0])
class DocumentType(Node):