--- /home/cpdev/src/classpath/gnu/xml/dom/DomDocument.java	2005-07-02 21:03:11.000000000 +0000
+++ gnu/xml/dom/DomDocument.java	2005-06-30 05:34:17.000000000 +0000
@@ -581,9 +581,7 @@
       }
     else
       {
-        DomElement domElement = new DomElement(this, null, name);
-        domElement.localName = null;
-        element = domElement;
+        element = new DomElement(this, null, name);
       }
     defaultAttributes(element, name);
     return element;
@@ -778,9 +776,7 @@
       }
     else
       {
-        DomAttr ret = new DomAttr(this, null, name);
-        ret.localName = null;
-        return ret;
+        return new DomAttr(this, null, name);
       }
   }
 
@@ -1159,8 +1155,7 @@
 
   public Node adoptNode(Node source)
   {
-    int sourceNodeType = source.getNodeType();
-    switch (sourceNodeType)
+    switch (source.getNodeType())
       {
       case DOCUMENT_NODE:
       case DOCUMENT_TYPE_NODE:
@@ -1171,7 +1166,6 @@
       }
     if (source instanceof DomNode)
       {
-        // GNU native
         DomNode src = (DomNode) source;
         DomNode dst = src;
         if (dst.parent != null)
@@ -1182,110 +1176,7 @@
         src.notifyUserDataHandlers(UserDataHandler.NODE_ADOPTED, src, dst);
         return dst;
       }
-    else
-      {
-        // Some other implementation
-        Node dst = null;
-        switch (sourceNodeType)
-          {
-          case Node.ATTRIBUTE_NODE:
-              {
-                Attr src = (Attr) source;
-                String nodeName = src.getNodeName();
-                String localName = src.getLocalName();
-                String namespaceUri = src.getNamespaceURI();
-                dst = (localName == null) ?
-                  createAttribute(nodeName) :
-                  createAttributeNS(namespaceUri, nodeName);
-                adoptChildren(src, dst);
-                break;
-              }
-          case Node.CDATA_SECTION_NODE:
-              {
-                CDATASection src = (CDATASection) source;
-                dst = createCDATASection(src.getData());
-                break;
-              }
-          case Node.COMMENT_NODE:
-              {
-                Comment src = (Comment) source;
-                dst = createComment(src.getData());
-                break;
-              }
-          case Node.DOCUMENT_FRAGMENT_NODE:
-              {
-                DocumentFragment src = (DocumentFragment) source;
-                dst = createDocumentFragment();
-                adoptChildren(src, dst);
-                break;
-              }
-          case Node.ELEMENT_NODE:
-              {
-                Element src = (Element) source;
-                String nodeName = src.getNodeName();
-                String localName = src.getLocalName();
-                String namespaceUri = src.getNamespaceURI();
-                dst = (localName == null) ?
-                  createElement(nodeName) :
-                  createElementNS(namespaceUri, nodeName);
-                adoptAttributes(src, dst);
-                adoptChildren(src, dst);
-                break;
-              }
-          case Node.ENTITY_REFERENCE_NODE:
-              {
-                EntityReference src = (EntityReference) source;
-                dst = createEntityReference(src.getNodeName());
-                adoptChildren(src, dst);
-                break;
-              }
-          case Node.PROCESSING_INSTRUCTION_NODE:
-              {
-                ProcessingInstruction src = (ProcessingInstruction) source;
-                dst = createProcessingInstruction(src.getTarget(),
-                                                  src.getData());
-                break;
-              }
-          case Node.TEXT_NODE:
-              {
-                Text src = (Text) source;
-                dst = createTextNode(src.getData());
-                break;
-              }
-          }
-        return dst;
-      }
-  }
-
-  void adoptChildren(Node src, Node dst)
-  {
-    Node node = src.getFirstChild();
-    while (node != null)
-      {
-        Node next = node.getNextSibling();
-        dst.appendChild(adoptNode(node));
-        node = next;
-      }
-  }
-
-  void adoptAttributes(Node src, Node dst)
-  {
-    NamedNodeMap srcAttrs = src.getAttributes();
-    NamedNodeMap dstAttrs = dst.getAttributes();
-    int len = srcAttrs.getLength();
-    for (int i = 0; i < len; i++)
-      {
-        Node node = srcAttrs.item(i);
-        String localName = node.getLocalName();
-        if (localName == null)
-          {
-            dstAttrs.setNamedItem(adoptNode(node));
-          }
-        else
-          {
-            dstAttrs.setNamedItemNS(adoptNode(node));
-          }
-      }
+    return null;
   }
 
   public DOMConfiguration getDomConfig()
