org.apache.xml.dtm.ref.dom2dtm
Class DOM2DTMdefaultNamespaceDeclarationNode

java.lang.Object
  |
  +--org.apache.xml.dtm.ref.dom2dtm.DOM2DTMdefaultNamespaceDeclarationNode

public class DOM2DTMdefaultNamespaceDeclarationNode
extends java.lang.Object
implements org.w3c.dom.Attr

This is a kluge to let us shove a declaration for xml: into the DOM2DTM model. Basically, it creates a proxy node in DOM space to carry the additional information. This is _NOT_ a full DOM implementation, and shouldn't be one since it sits alongside the DOM rather than becoming part of the DOM model. (This used to be an internal class within DOM2DTM. Moved out because I need to perform an instanceof operation on it to support a temporary workaround in DTMManagerDefault.) %REVIEW% What if the DOM2DTM was built around a DocumentFragment and there isn't a single root element? I think this fails that case... %REVIEW% An alternative solution would be to create the node _only_ in DTM space, but given how DOM2DTM is currently written I think this is simplest.


Method Summary
 org.w3c.dom.Node appendChild(org.w3c.dom.Node a)
           
 org.w3c.dom.Node cloneNode(boolean deep)
           
 org.w3c.dom.NamedNodeMap getAttributes()
           
 org.w3c.dom.NodeList getChildNodes()
           
 org.w3c.dom.Node getFirstChild()
           
 int getHandleOfNode()
          Non-DOM method, part of the temporary kluge %REVIEW% This would be a pruning problem, but since it will always be added to the root element and we prune on elements, we shouldn't have to worry.
 org.w3c.dom.Node getLastChild()
           
 java.lang.String getLocalName()
           
 java.lang.String getName()
           
 java.lang.String getNamespaceURI()
           
 org.w3c.dom.Node getNextSibling()
           
 java.lang.String getNodeName()
           
 short getNodeType()
           
 java.lang.String getNodeValue()
           
 org.w3c.dom.Document getOwnerDocument()
           
 org.w3c.dom.Element getOwnerElement()
           
 org.w3c.dom.Node getParentNode()
           
 java.lang.String getPrefix()
           
 org.w3c.dom.Node getPreviousSibling()
           
 boolean getSpecified()
           
 java.lang.String getValue()
           
 boolean hasAttributes()
           
 boolean hasChildNodes()
           
 org.w3c.dom.Node insertBefore(org.w3c.dom.Node a, org.w3c.dom.Node b)
           
 boolean isSupported(java.lang.String feature, java.lang.String version)
           
 void normalize()
           
 org.w3c.dom.Node removeChild(org.w3c.dom.Node a)
           
 org.w3c.dom.Node replaceChild(org.w3c.dom.Node a, org.w3c.dom.Node b)
           
 void setNodeValue(java.lang.String value)
           
 void setPrefix(java.lang.String value)
           
 void setValue(java.lang.String value)
           
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Method Detail

getNodeName

public java.lang.String getNodeName()

getName

public java.lang.String getName()
Specified by:
getName in interface org.w3c.dom.Attr

getNamespaceURI

public java.lang.String getNamespaceURI()

getPrefix

public java.lang.String getPrefix()

getLocalName

public java.lang.String getLocalName()

getNodeValue

public java.lang.String getNodeValue()

getValue

public java.lang.String getValue()
Specified by:
getValue in interface org.w3c.dom.Attr

getOwnerElement

public org.w3c.dom.Element getOwnerElement()
Specified by:
getOwnerElement in interface org.w3c.dom.Attr

isSupported

public boolean isSupported(java.lang.String feature,
                           java.lang.String version)

hasChildNodes

public boolean hasChildNodes()

hasAttributes

public boolean hasAttributes()

getParentNode

public org.w3c.dom.Node getParentNode()

getFirstChild

public org.w3c.dom.Node getFirstChild()

getLastChild

public org.w3c.dom.Node getLastChild()

getPreviousSibling

public org.w3c.dom.Node getPreviousSibling()

getNextSibling

public org.w3c.dom.Node getNextSibling()

getSpecified

public boolean getSpecified()
Specified by:
getSpecified in interface org.w3c.dom.Attr

normalize

public void normalize()

getChildNodes

public org.w3c.dom.NodeList getChildNodes()

getAttributes

public org.w3c.dom.NamedNodeMap getAttributes()

getNodeType

public short getNodeType()

setNodeValue

public void setNodeValue(java.lang.String value)

setValue

public void setValue(java.lang.String value)
Specified by:
setValue in interface org.w3c.dom.Attr

setPrefix

public void setPrefix(java.lang.String value)

insertBefore

public org.w3c.dom.Node insertBefore(org.w3c.dom.Node a,
                                     org.w3c.dom.Node b)

replaceChild

public org.w3c.dom.Node replaceChild(org.w3c.dom.Node a,
                                     org.w3c.dom.Node b)

appendChild

public org.w3c.dom.Node appendChild(org.w3c.dom.Node a)

removeChild

public org.w3c.dom.Node removeChild(org.w3c.dom.Node a)

getOwnerDocument

public org.w3c.dom.Document getOwnerDocument()

cloneNode

public org.w3c.dom.Node cloneNode(boolean deep)

getHandleOfNode

public int getHandleOfNode()
Non-DOM method, part of the temporary kluge %REVIEW% This would be a pruning problem, but since it will always be added to the root element and we prune on elements, we shouldn't have to worry.


Copyright © 2001 Apache XML Project. All Rights Reserved.