org.pasoa.dommap
Class SimpleDocument

java.lang.Object
  extended by org.pasoa.dommap.SimpleNode
      extended by org.pasoa.dommap.SimpleDocument
All Implemented Interfaces:
Document, Node
Direct Known Subclasses:
MappedDocument, SOAPDocument

public class SimpleDocument
extends SimpleNode
implements Document


Field Summary
 
Fields inherited from interface org.w3c.dom.Node
ATTRIBUTE_NODE, CDATA_SECTION_NODE, COMMENT_NODE, DOCUMENT_FRAGMENT_NODE, DOCUMENT_NODE, DOCUMENT_POSITION_CONTAINED_BY, DOCUMENT_POSITION_CONTAINS, DOCUMENT_POSITION_DISCONNECTED, DOCUMENT_POSITION_FOLLOWING, DOCUMENT_POSITION_IMPLEMENTATION_SPECIFIC, DOCUMENT_POSITION_PRECEDING, DOCUMENT_TYPE_NODE, ELEMENT_NODE, ENTITY_NODE, ENTITY_REFERENCE_NODE, NOTATION_NODE, PROCESSING_INSTRUCTION_NODE, TEXT_NODE
 
Constructor Summary
SimpleDocument(Document convertFrom)
           
SimpleDocument(Map prefixToSpace)
           
 
Method Summary
 Node adoptNode(Node source)
           
 SimpleNode cloneNode(boolean deep, Document newDocument)
           
 short compareDocumentPosition(Node other)
           
 Attr createAttribute(String name)
           
 Attr createAttributeNS(String namespaceURI, String qualifiedName)
           
 CDATASection createCDATASection(String data)
           
 Comment createComment(String data)
           
 DocumentFragment createDocumentFragment()
           
 Element createElement(String tagName)
           
 Element createElementNS(String namespaceURI, String qualifiedName)
           
 EntityReference createEntityReference(String name)
           
 ProcessingInstruction createProcessingInstruction(String target, String data)
           
 Text createTextNode(String data)
           
 String getAttribute(String name)
           
 Attr getAttributeNode(String name)
           
 String getAttributeNS(String namespaceURI, String localName)
           
 NamedNodeMap getAttributes()
           
 String getBaseURI()
           
 DocumentType getDoctype()
           
 Element getDocumentElement()
           
 String getDocumentURI()
           
 DOMConfiguration getDomConfig()
           
 Element getElementById(String elementId)
           
 NodeList getElementsByTagName(String tagname)
           
 NodeList getElementsByTagNameNS(String namespaceURI, String localName)
           
 Object getFeature(String feature, String version)
           
 DOMImplementation getImplementation()
           
 String getInputEncoding()
           
 String getLocalName()
           
 String getNamespaceURI()
           
 short getNodeType()
           
 String getNodeValue()
           
 Document getOwnerDocument()
           
 Node getPreviousSibling()
           
 TypeInfo getSchemaTypeInfo()
           
 boolean getStrictErrorChecking()
           
 String getTextContent()
           
 Object getUserData(String key)
           
 String getXmlEncoding()
           
 boolean getXmlStandalone()
           
 String getXmlVersion()
           
 boolean hasAttribute(String name)
           
 boolean hasAttributeNS(String namespaceURI, String localName)
           
 boolean hasAttributes()
           
 int hashCode()
           
 Node importNode(Node importedNode, boolean deep)
           
 Node insertBefore(Node newChild, Node refChild)
           
 boolean isDefaultNamespace(String namespaceURI)
           
 boolean isEqualNode(Node arg)
           
 boolean isSameNode(Node other)
           
 boolean isSupported(String feature, String version)
           
 String lookupNamespaceURI(String prefix)
           
 String lookupPrefix(String namespaceURI)
           
 void normalize()
           
 void normalizeDocument()
           
 void removeAttribute(String name)
           
 Attr removeAttributeNode(Attr oldAttr)
           
 void removeAttributeNS(String namespaceURI, String localName)
           
 Node removeChild(Node oldChild)
           
 Node renameNode(Node n, String namespaceURI, String qualifiedName)
           
 Node replaceChild(Node newChild, Node oldChild)
           
 void setAttribute(String name, String value)
           
 Attr setAttributeNode(Attr newAttr)
           
 void setDocumentURI(String documentURI)
           
 void setIdAttribute(String name, boolean isId)
           
 void setIdAttributeNode(Attr idAttr, boolean isId)
           
 void setIdAttributeNS(String namespaceURI, String localName, boolean isId)
           
 void setNodeValue(String nodeValue)
           
 void setPrefix(String prefix)
           
 void setStrictErrorChecking(boolean strictErrorChecking)
           
 void setTextContent(String textContent)
           
 Object setUserData(String key, Object data, UserDataHandler handler)
           
 void setXmlStandalone(boolean xmlStandalone)
           
 void setXmlVersion(String xmlVersion)
           
 
Methods inherited from class org.pasoa.dommap.SimpleNode
addNamespace, appendChild, cloneChildren, cloneNode, equals, getAllNamespaces, getAttributeNodeNS, getChildCount, getChildNodes, getFirstChild, getLastChild, getNamespaceForPrefix, getNextSibling, getNodeName, getParentNode, getPrefix, getPrefixForNamespace, getTagName, hasChildNodes, importInto, incorporateChild, setAttributeNodeNS, setAttributeNS, toString
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
 
Methods inherited from interface org.w3c.dom.Node
appendChild, cloneNode, getChildNodes, getFirstChild, getLastChild, getNextSibling, getNodeName, getParentNode, getPrefix, hasChildNodes
 

Constructor Detail

SimpleDocument

public SimpleDocument(Map prefixToSpace)

SimpleDocument

public SimpleDocument(Document convertFrom)
Method Detail

createAttribute

public Attr createAttribute(String name)
                     throws DOMException
Specified by:
createAttribute in interface Document
Throws:
DOMException

createAttributeNS

public Attr createAttributeNS(String namespaceURI,
                              String qualifiedName)
                       throws DOMException
Specified by:
createAttributeNS in interface Document
Throws:
DOMException

createElement

public Element createElement(String tagName)
                      throws DOMException
Specified by:
createElement in interface Document
Throws:
DOMException

createElementNS

public Element createElementNS(String namespaceURI,
                               String qualifiedName)
                        throws DOMException
Specified by:
createElementNS in interface Document
Throws:
DOMException

getDocumentElement

public Element getDocumentElement()
Specified by:
getDocumentElement in interface Document

getDoctype

public DocumentType getDoctype()
Specified by:
getDoctype in interface Document

getImplementation

public DOMImplementation getImplementation()
Specified by:
getImplementation in interface Document

getLocalName

public String getLocalName()
Specified by:
getLocalName in interface Node
Overrides:
getLocalName in class SimpleNode

getNamespaceURI

public String getNamespaceURI()
Specified by:
getNamespaceURI in interface Node
Overrides:
getNamespaceURI in class SimpleNode

getNodeType

public short getNodeType()
Specified by:
getNodeType in interface Node

getOwnerDocument

public Document getOwnerDocument()
Specified by:
getOwnerDocument in interface Node
Overrides:
getOwnerDocument in class SimpleNode

importNode

public Node importNode(Node importedNode,
                       boolean deep)
                throws DOMException
Specified by:
importNode in interface Document
Throws:
DOMException

setXmlStandalone

public void setXmlStandalone(boolean xmlStandalone)
                      throws DOMException
Specified by:
setXmlStandalone in interface Document
Throws:
DOMException

setStrictErrorChecking

public void setStrictErrorChecking(boolean strictErrorChecking)
Specified by:
setStrictErrorChecking in interface Document

cloneNode

public SimpleNode cloneNode(boolean deep,
                            Document newDocument)

setUserData

public Object setUserData(String key,
                          Object data,
                          UserDataHandler handler)
Specified by:
setUserData in interface Node

renameNode

public Node renameNode(Node n,
                       String namespaceURI,
                       String qualifiedName)
                throws DOMException
Specified by:
renameNode in interface Document
Throws:
DOMException

setXmlVersion

public void setXmlVersion(String xmlVersion)
                   throws DOMException
Specified by:
setXmlVersion in interface Document
Throws:
DOMException

setTextContent

public void setTextContent(String textContent)
                    throws DOMException
Specified by:
setTextContent in interface Node
Throws:
DOMException

setPrefix

public void setPrefix(String prefix)
               throws DOMException
Specified by:
setPrefix in interface Node
Throws:
DOMException

setNodeValue

public void setNodeValue(String nodeValue)
                  throws DOMException
Specified by:
setNodeValue in interface Node
Throws:
DOMException

setDocumentURI

public void setDocumentURI(String documentURI)
Specified by:
setDocumentURI in interface Document

lookupPrefix

public String lookupPrefix(String namespaceURI)
Specified by:
lookupPrefix in interface Node

lookupNamespaceURI

public String lookupNamespaceURI(String prefix)
Specified by:
lookupNamespaceURI in interface Node

isDefaultNamespace

public boolean isDefaultNamespace(String namespaceURI)
Specified by:
isDefaultNamespace in interface Node

getElementById

public Element getElementById(String elementId)
Specified by:
getElementById in interface Document

createTextNode

public Text createTextNode(String data)
Specified by:
createTextNode in interface Document

createCDATASection

public CDATASection createCDATASection(String data)
                                throws DOMException
Specified by:
createCDATASection in interface Document
Throws:
DOMException

createComment

public Comment createComment(String data)
Specified by:
createComment in interface Document

createEntityReference

public EntityReference createEntityReference(String name)
                                      throws DOMException
Specified by:
createEntityReference in interface Document
Throws:
DOMException

getElementsByTagName

public NodeList getElementsByTagName(String tagname)
Specified by:
getElementsByTagName in interface Document

getUserData

public Object getUserData(String key)
Specified by:
getUserData in interface Node

removeChild

public Node removeChild(Node oldChild)
                 throws DOMException
Specified by:
removeChild in interface Node
Throws:
DOMException

isSameNode

public boolean isSameNode(Node other)
Specified by:
isSameNode in interface Node
Overrides:
isSameNode in class SimpleNode

isEqualNode

public boolean isEqualNode(Node arg)
Specified by:
isEqualNode in interface Node
Overrides:
isEqualNode in class SimpleNode

adoptNode

public Node adoptNode(Node source)
               throws DOMException
Specified by:
adoptNode in interface Document
Throws:
DOMException

compareDocumentPosition

public short compareDocumentPosition(Node other)
                              throws DOMException
Specified by:
compareDocumentPosition in interface Node
Throws:
DOMException

replaceChild

public Node replaceChild(Node newChild,
                         Node oldChild)
                  throws DOMException
Specified by:
replaceChild in interface Node
Throws:
DOMException

normalizeDocument

public void normalizeDocument()
Specified by:
normalizeDocument in interface Document

normalize

public void normalize()
Specified by:
normalize in interface Node

isSupported

public boolean isSupported(String feature,
                           String version)
Specified by:
isSupported in interface Node

insertBefore

public Node insertBefore(Node newChild,
                         Node refChild)
                  throws DOMException
Specified by:
insertBefore in interface Node
Throws:
DOMException

getDomConfig

public DOMConfiguration getDomConfig()
Specified by:
getDomConfig in interface Document

getDocumentURI

public String getDocumentURI()
Specified by:
getDocumentURI in interface Document

getBaseURI

public String getBaseURI()
Specified by:
getBaseURI in interface Node

getAttributes

public NamedNodeMap getAttributes()
Specified by:
getAttributes in interface Node
Overrides:
getAttributes in class SimpleNode

createProcessingInstruction

public ProcessingInstruction createProcessingInstruction(String target,
                                                         String data)
                                                  throws DOMException
Specified by:
createProcessingInstruction in interface Document
Throws:
DOMException

createDocumentFragment

public DocumentFragment createDocumentFragment()
Specified by:
createDocumentFragment in interface Document

getElementsByTagNameNS

public NodeList getElementsByTagNameNS(String namespaceURI,
                                       String localName)
Specified by:
getElementsByTagNameNS in interface Document

getFeature

public Object getFeature(String feature,
                         String version)
Specified by:
getFeature in interface Node

getInputEncoding

public String getInputEncoding()
Specified by:
getInputEncoding in interface Document

getNodeValue

public String getNodeValue()
                    throws DOMException
Specified by:
getNodeValue in interface Node
Throws:
DOMException

getPreviousSibling

public Node getPreviousSibling()
Specified by:
getPreviousSibling in interface Node

getStrictErrorChecking

public boolean getStrictErrorChecking()
Specified by:
getStrictErrorChecking in interface Document

getTextContent

public String getTextContent()
                      throws DOMException
Specified by:
getTextContent in interface Node
Throws:
DOMException

getXmlEncoding

public String getXmlEncoding()
Specified by:
getXmlEncoding in interface Document

getXmlStandalone

public boolean getXmlStandalone()
Specified by:
getXmlStandalone in interface Document

getXmlVersion

public String getXmlVersion()
Specified by:
getXmlVersion in interface Document

hasAttributes

public boolean hasAttributes()
Specified by:
hasAttributes in interface Node
Overrides:
hasAttributes in class SimpleNode

hashCode

public int hashCode()
Overrides:
hashCode in class Object

setIdAttributeNode

public void setIdAttributeNode(Attr idAttr,
                               boolean isId)
                        throws DOMException
Throws:
DOMException

setAttributeNode

public Attr setAttributeNode(Attr newAttr)
                      throws DOMException
Throws:
DOMException

removeAttributeNode

public Attr removeAttributeNode(Attr oldAttr)
                         throws DOMException
Throws:
DOMException

getAttribute

public String getAttribute(String name)

getAttributeNode

public Attr getAttributeNode(String name)

hasAttribute

public boolean hasAttribute(String name)

removeAttribute

public void removeAttribute(String name)
                     throws DOMException
Throws:
DOMException

setIdAttributeNS

public void setIdAttributeNS(String namespaceURI,
                             String localName,
                             boolean isId)
                      throws DOMException
Throws:
DOMException

setIdAttribute

public void setIdAttribute(String name,
                           boolean isId)
                    throws DOMException
Throws:
DOMException

setAttribute

public void setAttribute(String name,
                         String value)
                  throws DOMException
Throws:
DOMException

getAttributeNS

public String getAttributeNS(String namespaceURI,
                             String localName)
                      throws DOMException
Throws:
DOMException

getSchemaTypeInfo

public TypeInfo getSchemaTypeInfo()

hasAttributeNS

public boolean hasAttributeNS(String namespaceURI,
                              String localName)
                       throws DOMException
Throws:
DOMException

removeAttributeNS

public void removeAttributeNS(String namespaceURI,
                              String localName)
                       throws DOMException
Throws:
DOMException