Package org.apache.axis.message
Class SOAPDocumentImpl
java.lang.Object
org.apache.axis.message.SOAPDocumentImpl
- All Implemented Interfaces:
Serializable,Document,Node
SOAPDcoumentImpl implements the Document API for SOAPPART. At the moment, it
again delgate the XERCES DOM Implementation Here is my argument on it: I
guess that there is 3 way to implement this. - fully implement the DOM API
here myself. => This is too much and duplicated work. - extends XERCES
Implementation => this makes we are fixed to one Implementation - choose
delgate depends on the user's parser preference => This is the practically
best solution I have now
- Author:
- Heejune Ahn (cityboy@tmax.co.kr)
- See Also:
-
Field Summary
FieldsFields 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
Constructors -
Method Summary
Modifier and TypeMethodDescriptionappendChild(Node newChild) cloneNode(boolean deep) shortcompareDocumentPosition(Node other) createAttribute(String name) createAttributeNS(String namespaceURI, String qualifiedName) Attribute is not particularly dealt with in SAAJ.createCDATASection(String data) Creates aCDATASectionnode whose value is the specified string.createComment(String data) Creates aCommentnode given the specified string.Creates an emptyDocumentFragmentobject.createElement(String tagName) based on the tagName, we will make different kind SOAP Elements Instance Is really we can determine the Type by the Tagname???createElementNS(String namespaceURI, String qualifiedName) Return SOAPElements (what if they want SOAPEnvelope or Header/Body?)createEntityReference(String name) createProcessingInstruction(String target, String data) Creates aProcessingInstructionnode given the specified name and data strings.createTextNode(String data) Creates aTextnode given the specified string.DOM Level 3 stubsshould not be called, the method will be handled in SOAPPartgetElementById(String elementId) Returns theElementwhoseIDis given byelementId.getElementsByTagName(String localName) search the SOAPPart in order of SOAPHeader and SOAPBody for the requested Element namegetElementsByTagNameNS(String namespaceURI, String localName) search the SOAPPart in order of SOAPHeader and SOAPBody for the requested Element namegetFeature(String feature, String version) Do we have to count the Attributes as node ????Node Implementationshortoverride it in sub-classeswe have to have a link to them...booleangetUserData(String key) booleanbooleanbooleanimportNode(Node importedNode, boolean deep) insertBefore(Node newChild, Node refChild) booleanisDefaultNamespace(String namespaceURI) booleanisEqualNode(Node arg) booleanisSameNode(Node other) booleanisSupported(String feature, String version) lookupNamespaceURI(String prefix) lookupPrefix(String namespaceURI) voidvoidremoveChild(Node oldChild) renameNode(Node n, String namespaceURI, String qualifiedName) replaceChild(Node newChild, Node oldChild) voidsetDocumentURI(String documentURI) voidsetNamespaceURI(String nsURI) voidsetNodeValue(String nodeValue) voidvoidsetStrictErrorChecking(boolean strictErrorChecking) voidsetTextContent(String textContent) setUserData(String key, Object data, UserDataHandler handler) voidsetXmlStandalone(boolean xmlStandalone) voidsetXmlVersion(String xmlVersion)
-
Field Details
-
delegate
-
soapPart
-
-
Constructor Details
-
SOAPDocumentImpl
Construct the Document- Parameters:
sp- the soap part
-
-
Method Details
-
getDoctype
- Specified by:
getDoctypein interfaceDocument- Returns:
-
getImplementation
- Specified by:
getImplementationin interfaceDocument
-
getDocumentElement
should not be called, the method will be handled in SOAPPart- Specified by:
getDocumentElementin interfaceDocument- Returns:
-
createElement
based on the tagName, we will make different kind SOAP Elements Instance Is really we can determine the Type by the Tagname???- Specified by:
createElementin interfaceDocument- Parameters:
tagName-- Returns:
- @throws DOMException
- Throws:
DOMException
-
createDocumentFragment
Creates an emptyDocumentFragmentobject. @todo not implemented yet- Specified by:
createDocumentFragmentin interfaceDocument- Returns:
- A new
DocumentFragment.
-
createTextNode
Creates aTextnode given the specified string.- Specified by:
createTextNodein interfaceDocument- Parameters:
data- The data for the node.- Returns:
- The new
Textobject.
-
createComment
Creates aCommentnode given the specified string.- Specified by:
createCommentin interfaceDocument- Parameters:
data- The data for the node.- Returns:
- The new
Commentobject.
-
createCDATASection
Creates aCDATASectionnode whose value is the specified string.- Specified by:
createCDATASectionin interfaceDocument- Parameters:
data- The data for theCDATASectioncontents.- Returns:
- The new
CDATASectionobject. - Throws:
DOMException- NOT_SUPPORTED_ERR: Raised if this document is an HTML document.
-
createProcessingInstruction
public ProcessingInstruction createProcessingInstruction(String target, String data) throws DOMException Creates aProcessingInstructionnode given the specified name and data strings.- Specified by:
createProcessingInstructionin interfaceDocument- Parameters:
target- The target part of the processing instruction.data- The data for the node.- Returns:
- The new
ProcessingInstructionobject. - Throws:
DOMException- INVALID_CHARACTER_ERR: Raised if the specified target contains an illegal character.
NOT_SUPPORTED_ERR: Raised if this document is an HTML document.
-
createAttribute
- Specified by:
createAttributein interfaceDocument- Throws:
DOMException
-
createEntityReference
- Specified by:
createEntityReferencein interfaceDocument- Parameters:
name-- Returns:
- @throws DOMException
- Throws:
DOMException
-
importNode
- Specified by:
importNodein interfaceDocument- Throws:
DOMException
-
createElementNS
Return SOAPElements (what if they want SOAPEnvelope or Header/Body?)- Specified by:
createElementNSin interfaceDocument- Parameters:
namespaceURI-qualifiedName-- Returns:
- @throws DOMException
- Throws:
DOMException
-
createAttributeNS
Attribute is not particularly dealt with in SAAJ.- Specified by:
createAttributeNSin interfaceDocument- Throws:
DOMException
-
getElementsByTagNameNS
search the SOAPPart in order of SOAPHeader and SOAPBody for the requested Element name- Specified by:
getElementsByTagNameNSin interfaceDocument
-
getElementsByTagName
search the SOAPPart in order of SOAPHeader and SOAPBody for the requested Element name- Specified by:
getElementsByTagNamein interfaceDocument
-
getElementById
Returns theElementwhoseIDis given byelementId. If no such element exists, returnsnull. Behavior is not defined if more than one element has thisID. The DOM implementation must have information that says which attributes are of type ID. Attributes with the name "ID" are not of type ID unless so defined. Implementations that do not know whether attributes are of type ID or not are expected to returnnull.- Specified by:
getElementByIdin interfaceDocument- Parameters:
elementId- The uniqueidvalue for an element.- Returns:
- The matching element.
- Since:
- DOM Level 2
-
getNodeName
Node Implementation- Specified by:
getNodeNamein interfaceNode
-
getNodeValue
- Specified by:
getNodeValuein interfaceNode- Throws:
DOMException
-
setNodeValue
- Specified by:
setNodeValuein interfaceNode- Throws:
DOMException
-
getNodeType
public short getNodeType()override it in sub-classes- Specified by:
getNodeTypein interfaceNode- Returns:
-
getParentNode
- Specified by:
getParentNodein interfaceNode
-
getChildNodes
- Specified by:
getChildNodesin interfaceNode
-
getFirstChild
Do we have to count the Attributes as node ????- Specified by:
getFirstChildin interfaceNode- Returns:
-
getLastChild
- Specified by:
getLastChildin interfaceNode- Returns:
-
getPreviousSibling
- Specified by:
getPreviousSiblingin interfaceNode
-
getNextSibling
- Specified by:
getNextSiblingin interfaceNode
-
getAttributes
- Specified by:
getAttributesin interfaceNode
-
getOwnerDocument
we have to have a link to them...- Specified by:
getOwnerDocumentin interfaceNode
-
insertBefore
- Specified by:
insertBeforein interfaceNode- Throws:
DOMException
-
replaceChild
- Specified by:
replaceChildin interfaceNode- Throws:
DOMException
-
removeChild
- Specified by:
removeChildin interfaceNode- Throws:
DOMException
-
appendChild
- Specified by:
appendChildin interfaceNode- Throws:
DOMException
-
hasChildNodes
public boolean hasChildNodes()- Specified by:
hasChildNodesin interfaceNode
-
cloneNode
-
normalize
public void normalize() -
isSupported
- Specified by:
isSupportedin interfaceNode
-
getPrefix
-
setPrefix
-
getNamespaceURI
- Specified by:
getNamespaceURIin interfaceNode
-
setNamespaceURI
-
getLocalName
- Specified by:
getLocalNamein interfaceNode
-
hasAttributes
public boolean hasAttributes()- Specified by:
hasAttributesin interfaceNode
-
getBaseURI
DOM Level 3 stubs- Specified by:
getBaseURIin interfaceNode
-
getXmlStandalone
public boolean getXmlStandalone()- Specified by:
getXmlStandalonein interfaceDocument
-
getStrictErrorChecking
public boolean getStrictErrorChecking()- Specified by:
getStrictErrorCheckingin interfaceDocument
-
setXmlStandalone
public void setXmlStandalone(boolean xmlStandalone) - Specified by:
setXmlStandalonein interfaceDocument
-
renameNode
- Specified by:
renameNodein interfaceDocument
-
setStrictErrorChecking
public void setStrictErrorChecking(boolean strictErrorChecking) - Specified by:
setStrictErrorCheckingin interfaceDocument
-
setUserData
- Specified by:
setUserDatain interfaceNode
-
getInputEncoding
- Specified by:
getInputEncodingin interfaceDocument
-
getXmlEncoding
- Specified by:
getXmlEncodingin interfaceDocument
-
setTextContent
- Specified by:
setTextContentin interfaceNode
-
isSameNode
- Specified by:
isSameNodein interfaceNode
-
getDocumentURI
- Specified by:
getDocumentURIin interfaceDocument
-
setDocumentURI
- Specified by:
setDocumentURIin interfaceDocument
-
getFeature
- Specified by:
getFeaturein interfaceNode
-
adoptNode
-
isDefaultNamespace
- Specified by:
isDefaultNamespacein interfaceNode
-
isEqualNode
- Specified by:
isEqualNodein interfaceNode
-
setXmlVersion
- Specified by:
setXmlVersionin interfaceDocument
-
getXmlVersion
- Specified by:
getXmlVersionin interfaceDocument
-
lookupPrefix
- Specified by:
lookupPrefixin interfaceNode
-
getUserData
- Specified by:
getUserDatain interfaceNode
-
getTextContent
- Specified by:
getTextContentin interfaceNode
-
normalizeDocument
public void normalizeDocument()- Specified by:
normalizeDocumentin interfaceDocument
-
lookupNamespaceURI
- Specified by:
lookupNamespaceURIin interfaceNode
-
getDomConfig
- Specified by:
getDomConfigin interfaceDocument
-
compareDocumentPosition
- Specified by:
compareDocumentPositionin interfaceNode
-