- All Implemented Interfaces:
Node,SOAPBody,SOAPBodyElement,SOAPElement,Element,Node
- Direct Known Subclasses:
Body1_1Impl,Body1_2Impl
-
Field Summary
Fields inherited from class com.sun.xml.messaging.saaj.soap.impl.ElementImpl
DSIG_NS, elementQName, WSU_NS, XENC_NSFields 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
ConstructorsModifierConstructorDescriptionprotectedBodyImpl(SOAPDocumentImpl ownerDoc, NameImpl bodyName) protectedBodyImpl(SOAPDocumentImpl ownerDoc, Element domElement) -
Method Summary
Modifier and TypeMethodDescriptionaddBodyElement(Name name) Creates a newSOAPBodyElementobject with the specified name and adds it to thisSOAPBodyobject.addBodyElement(QName qname) Creates a newSOAPBodyElementobject with the specified QName and adds it to thisSOAPBodyobject.addDocument(Document document) Adds the root node of the DOMDocumentto thisSOAPBodyobject.protected SOAPElementaddElement(Name name) protected SOAPElementaddElement(QName name) addFault()Creates a newSOAPFaultobject and adds it to thisSOAPBodyobject.Creates a newSOAPFaultobject and adds it to thisSOAPBodyobject.Creates a newSOAPFaultobject and adds it to thisSOAPBodyobject.Creates a newSOAPFaultobject and adds it to thisSOAPBodyobject.Creates a newSOAPFaultobject and adds it to thisSOAPBodyobject.protected SOAPElementconvertToSoapElement(Element element) protected abstract SOAPBodyElementcreateBodyElement(Name name) protected abstract SOAPBodyElementcreateBodyElement(QName name) protected abstract SOAPFaultCreates a new DOMDocumentand sets the first child of thisSOAPBodyas it's document element.protected SOAPElementprotected abstract QNamegetFault()Returns theSOAPFaultobject in thisSOAPBodyobject.protected abstract NameImplgetFaultName(String name) booleanbooleanhasFault()Indicates whether aSOAPFaultobject exists in thisSOAPBodyobject.protected abstract booleanisFault(SOAPElement child) booleanisLazy()setElementQName(QName newName) Changes the name of thisElementtonewNameif possible.voidsetParentElement(SOAPElement element) Sets the parent of thisNodeobject to the givenSOAPElementobject.Methods inherited from class com.sun.xml.messaging.saaj.soap.impl.ElementImpl
addAttribute, addAttribute, addCDATA, addChildElement, addChildElement, addChildElement, addChildElement, addChildElement, addChildElement, addNamespaceDeclaration, addNode, addText, addTextNode, appendChild, cloneNode, compareDocumentPosition, convertToSoapText, createElement, createElement, createQName, detachNode, doGetNamespacePrefixes, ensureNamespaceIsDeclared, findAndConvertChildElement, findChild, findEncodingStyleAttributeName, getAllAttributes, getAllAttributesAsQNames, getAllAttributesFrom, getAttribute, getAttributeNode, getAttributeNodeNS, getAttributeNS, getAttributes, getAttributeValue, getAttributeValue, getAttributeValueFrom, getBaseURI, getChildElementNodes, getChildElements, getChildElements, getChildElements, getChildElementsFrom, getDomElement, getElementName, getElementQName, getElementsByTagName, getElementsByTagNameNS, getEncodingStyle, getFeature, getLocalName, getLocalPart, getNamespaceAttr, getNamespaceAttrFrom, getNamespaceContextNodes, getNamespaceContextNodes, getNamespacePrefix, getNamespacePrefixes, getNamespaceURI, getNamespaceURI, getNextSibling, getNodeName, getNodeType, getNodeValue, getOwnerDocument, getParentElement, getParentNode, getPrefix, getPrefix, getPreviousSibling, getQualifiedName, getSchemaTypeInfo, getSoapDocument, getSOAPNamespace, getTagName, getTextContent, getUserData, getValue, getValueNode, getValueNodeStrict, getVisibleNamespacePrefixes, hasAttribute, hasAttributeNS, hasAttributes, importElement, insertBefore, isDefaultNamespace, isEqualNode, isNamespaceQualified, isNamespaceQualified, isSameNode, isSupported, lookupNamespaceURI, lookupPrefix, normalize, recycleNode, removeAttribute, removeAttribute, removeAttribute, removeAttributeNode, removeAttributeNS, removeChild, removeContents, removeNamespaceDeclaration, replaceChild, replaceElementWithSOAPElement, setAttribute, setAttributeNode, setAttributeNodeNS, setAttributeNS, setEncodingStyle, setEncodingStyleNamespace, setIdAttribute, setIdAttributeNode, setIdAttributeNS, setNodeValue, setPrefix, setTextContent, setUserData, setValue, tryToFindEncodingStyleAttributeNameMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface org.w3c.dom.Element
getAttribute, getAttributeNode, getAttributeNodeNS, getAttributeNS, getElementsByTagName, getElementsByTagNameNS, getSchemaTypeInfo, getTagName, hasAttribute, hasAttributeNS, removeAttribute, removeAttributeNode, removeAttributeNS, setAttribute, setAttributeNode, setAttributeNodeNS, setAttributeNS, setIdAttribute, setIdAttributeNode, setIdAttributeNSMethods inherited from interface jakarta.xml.soap.Node
detachNode, getParentElement, getValue, recycleNode, setValueMethods inherited from interface org.w3c.dom.Node
appendChild, cloneNode, compareDocumentPosition, getAttributes, getBaseURI, getFeature, getLocalName, getNamespaceURI, getNextSibling, getNodeName, getNodeType, getNodeValue, getOwnerDocument, getParentNode, getPrefix, getPreviousSibling, getTextContent, getUserData, hasAttributes, insertBefore, isDefaultNamespace, isEqualNode, isSameNode, isSupported, lookupNamespaceURI, lookupPrefix, normalize, removeChild, replaceChild, setNodeValue, setPrefix, setTextContent, setUserDataMethods inherited from interface jakarta.xml.soap.SOAPElement
addAttribute, addAttribute, addChildElement, addChildElement, addChildElement, addChildElement, addChildElement, addChildElement, addNamespaceDeclaration, addTextNode, createQName, getAllAttributes, getAllAttributesAsQNames, getAttributeValue, getAttributeValue, getChildElements, getChildElements, getChildElements, getElementName, getElementQName, getEncodingStyle, getNamespacePrefixes, getNamespaceURI, getVisibleNamespacePrefixes, removeAttribute, removeAttribute, removeContents, removeNamespaceDeclaration, setEncodingStyle
-
Constructor Details
-
BodyImpl
-
BodyImpl
-
-
Method Details
-
getFaultName
-
isFault
-
createBodyElement
-
createBodyElement
-
createFaultElement
-
getDefaultFaultCode
-
addFault
Description copied from interface:SOAPBodyCreates a newSOAPFaultobject and adds it to thisSOAPBodyobject. The newSOAPFaultwill have default values set for the mandatory child elements. The type of theSOAPFaultwill be a SOAP 1.1 or a SOAP 1.2SOAPFaultdepending on theprotocolspecified while creating theMessageFactoryinstance.A
SOAPBodymay contain at most oneSOAPFaultchild element.- Specified by:
addFaultin interfaceSOAPBody- Returns:
- the new
SOAPFaultobject - Throws:
SOAPException- if there is a SOAP error
-
addFault
Description copied from interface:SOAPBodyCreates a newSOAPFaultobject and adds it to thisSOAPBodyobject. The type of theSOAPFaultwill be a SOAP 1.1 or a SOAP 1.2SOAPFaultdepending on theprotocolspecified while creating theMessageFactoryinstance.For SOAP 1.2 the
faultCodeparameter is the value of the Fault/Code/Value element and thefaultStringparameter is the value of the Fault/Reason/Text element. For SOAP 1.1 thefaultCodeparameter is the value of thefaultcodeelement and thefaultStringparameter is the value of thefaultstringelement.A
SOAPBodymay contain at most oneSOAPFaultchild element.- Specified by:
addFaultin interfaceSOAPBody- Parameters:
faultCode- aNameobject giving the fault code to be set; must be one of the fault codes defined in the Version of SOAP specification in usefaultString- aStringgiving an explanation of the faultlocale- aLocaleobject indicating the native language of thefaultString- Returns:
- the new
SOAPFaultobject - Throws:
SOAPException- if there is a SOAP error- See Also:
-
addFault
Description copied from interface:SOAPBodyCreates a newSOAPFaultobject and adds it to thisSOAPBodyobject. The type of theSOAPFaultwill be a SOAP 1.1 or a SOAP 1.2SOAPFaultdepending on theprotocolspecified while creating theMessageFactoryinstance.For SOAP 1.2 the
faultCodeparameter is the value of the Fault/Code/Value element and thefaultStringparameter is the value of the Fault/Reason/Text element. For SOAP 1.1 thefaultCodeparameter is the value of thefaultcodeelement and thefaultStringparameter is the value of thefaultstringelement.A
SOAPBodymay contain at most oneSOAPFaultchild element.- Specified by:
addFaultin interfaceSOAPBody- Parameters:
faultCode- aQNameobject giving the fault code to be set; must be one of the fault codes defined in the version of SOAP specification in use.faultString- aStringgiving an explanation of the faultlocale- aLocaleobject indicating the native language of thefaultString- Returns:
- the new
SOAPFaultobject - Throws:
SOAPException- if there is a SOAP error- See Also:
-
addFault
Description copied from interface:SOAPBodyCreates a newSOAPFaultobject and adds it to thisSOAPBodyobject. The type of theSOAPFaultwill be a SOAP 1.1 or a SOAP 1.2SOAPFaultdepending on theprotocolspecified while creating theMessageFactoryinstance.For SOAP 1.2 the
faultCodeparameter is the value of the Fault/Code/Value element and thefaultStringparameter is the value of the Fault/Reason/Text element. For SOAP 1.1 thefaultCodeparameter is the value of the faultcode element and thefaultStringparameter is the value of the faultstring element.In case of a SOAP 1.2 fault, the default value for the mandatory
xml:langattribute on the Fault/Reason/Text element will be set tojava.util.Locale.getDefault()A
SOAPBodymay contain at most oneSOAPFaultchild element.- Specified by:
addFaultin interfaceSOAPBody- Parameters:
faultCode- aNameobject giving the fault code to be set; must be one of the fault codes defined in the version of SOAP specification in usefaultString- aStringgiving an explanation of the fault- Returns:
- the new
SOAPFaultobject - Throws:
SOAPException- if there is a SOAP error- See Also:
-
addFault
Description copied from interface:SOAPBodyCreates a newSOAPFaultobject and adds it to thisSOAPBodyobject. The type of theSOAPFaultwill be a SOAP 1.1 or a SOAP 1.2SOAPFaultdepending on theprotocolspecified while creating theMessageFactoryinstance.For SOAP 1.2 the
faultCodeparameter is the value of the Fault/Code/Value element and thefaultStringparameter is the value of the Fault/Reason/Text element. For SOAP 1.1 thefaultCodeparameter is the value of the faultcode element and thefaultStringparameter is the value of the faultstring element.In case of a SOAP 1.2 fault, the default value for the mandatory
xml:langattribute on the Fault/Reason/Text element will be set tojava.util.Locale.getDefault()A
SOAPBodymay contain at most oneSOAPFaultchild element- Specified by:
addFaultin interfaceSOAPBody- Parameters:
faultCode- aQNameobject giving the fault code to be set; must be one of the fault codes defined in the version of SOAP specification in usefaultString- aStringgiving an explanation of the fault- Returns:
- the new
SOAPFaultobject - Throws:
SOAPException- if there is a SOAP error- See Also:
-
findFault
-
hasFault
public boolean hasFault()Description copied from interface:SOAPBodyIndicates whether aSOAPFaultobject exists in thisSOAPBodyobject. -
getFault
Description copied from interface:SOAPBodyReturns theSOAPFaultobject in thisSOAPBodyobject. -
addBodyElement
Description copied from interface:SOAPBodyCreates a newSOAPBodyElementobject with the specified name and adds it to thisSOAPBodyobject.- Specified by:
addBodyElementin interfaceSOAPBody- Parameters:
name- aNameobject with the name for the newSOAPBodyElementobject- Returns:
- the new
SOAPBodyElementobject - Throws:
SOAPException- if a SOAP error occurs- See Also:
-
addBodyElement
Description copied from interface:SOAPBodyCreates a newSOAPBodyElementobject with the specified QName and adds it to thisSOAPBodyobject.- Specified by:
addBodyElementin interfaceSOAPBody- Parameters:
qname- aQNameobject with the qname for the newSOAPBodyElementobject- Returns:
- the new
SOAPBodyElementobject - Throws:
SOAPException- if a SOAP error occurs- See Also:
-
setParentElement
Description copied from interface:NodeSets the parent of thisNodeobject to the givenSOAPElementobject.- Specified by:
setParentElementin interfaceNode- Overrides:
setParentElementin classElementImpl- Parameters:
element- theSOAPElementobject to be set as the parent of thisNodeobject- Throws:
SOAPException- if there is a problem in setting the parent to the given element- See Also:
-
addElement
- Overrides:
addElementin classElementImpl- Throws:
SOAPException
-
addElement
- Overrides:
addElementin classElementImpl- Throws:
SOAPException
-
addDocument
Description copied from interface:SOAPBodyAdds the root node of the DOMDocumentto thisSOAPBodyobject.Calling this method invalidates the
documentparameter. The client application should discard all references to thisDocumentand its contents upon callingaddDocument. The behavior of an application that continues to use such references is undefined.- Specified by:
addDocumentin interfaceSOAPBody- Parameters:
document- theDocumentobject whose root node will be added to thisSOAPBody.- Returns:
- the
SOAPBodyElementthat represents the root node that was added. - Throws:
SOAPException- if theDocumentcannot be added
-
convertToSoapElement
- Overrides:
convertToSoapElementin classElementImpl
-
setElementQName
Description copied from interface:SOAPElementChanges the name of thisElementtonewNameif possible. SOAP Defined elements such as SOAPEnvelope, SOAPHeader, SOAPBody etc. cannot have their names changed using this method. Any attempt to do so will result in a SOAPException being thrown.Callers should not rely on the element instance being renamed as is. Implementations could end up copying the content of the
SOAPElementto a renamed instance.- Specified by:
setElementQNamein interfaceSOAPElement- Overrides:
setElementQNamein classElementImpl- Parameters:
newName- the new name for theElement.- Returns:
- The renamed Node
- Throws:
SOAPException- if changing the name of thisElementis not allowed.
-
extractContentAsDocument
Description copied from interface:SOAPBodyCreates a new DOMDocumentand sets the first child of thisSOAPBodyas it's document element. The childSOAPElementis removed as part of the process.- Specified by:
extractContentAsDocumentin interfaceSOAPBody- Returns:
- the
Documentrepresentation of theSOAPBodycontent. - Throws:
SOAPException- if there is not exactly one childSOAPElementof theSOAPBody.
-
hasChildNodes
public boolean hasChildNodes()- Specified by:
hasChildNodesin interfaceNode- Overrides:
hasChildNodesin classElementImpl
-
getChildNodes
- Specified by:
getChildNodesin interfaceNode- Overrides:
getChildNodesin classElementImpl
-
getFirstChild
- Specified by:
getFirstChildin interfaceNode- Overrides:
getFirstChildin classElementImpl
-
getFirstChildNoMaterialize
-
getLastChild
- Specified by:
getLastChildin interfaceNode- Overrides:
getLastChildin classElementImpl
-
isLazy
public boolean isLazy()
-