| <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd"> |
| <!-- NewPage --> |
| <html lang="en"> |
| <head> |
| <title>SOAPEnvelope</title> |
| <link rel="stylesheet" type="text/css" href="../../../stylesheet.css" title="Style"> |
| <script type="text/javascript" src="../../../script.js"></script> |
| </head> |
| <body> |
| <script type="text/javascript"><!-- |
| try { |
| if (location.href.indexOf('is-external=true') == -1) { |
| parent.document.title="SOAPEnvelope"; |
| } |
| } |
| catch(err) { |
| } |
| //--> |
| var methods = {"i0":6,"i1":6,"i2":6,"i3":6,"i4":6,"i5":6}; |
| var tabs = {65535:["t0","All Methods"],2:["t2","Instance Methods"],4:["t3","Abstract Methods"]}; |
| var altColor = "altColor"; |
| var rowColor = "rowColor"; |
| var tableTab = "tableTab"; |
| var activeTableTab = "activeTableTab"; |
| </script> |
| <noscript> |
| <div>JavaScript is disabled on your browser.</div> |
| </noscript> |
| <!-- ========= START OF TOP NAVBAR ======= --> |
| <div class="topNav"><a name="navbar.top"> |
| <!-- --> |
| </a> |
| <div class="skipNav"><a href="#skip.navbar.top" title="Skip navigation links">Skip navigation links</a></div> |
| <a name="navbar.top.firstrow"> |
| <!-- --> |
| </a> |
| <ul class="navList" title="Navigation"> |
| <li><a href="../../../overview-summary.html">Overview</a></li> |
| <li><a href="package-summary.html">Package</a></li> |
| <li class="navBarCell1Rev">Class</li> |
| <li><a href="package-tree.html">Tree</a></li> |
| <li><a href="../../../deprecated-list.html">Deprecated</a></li> |
| <li><a href="../../../index-all.html">Index</a></li> |
| <li><a href="../../../help-doc.html">Help</a></li> |
| </ul> |
| </div> |
| <div class="subNav"> |
| <ul class="navList"> |
| <li><a href="../../../javax/xml/soap/SOAPElementFactory.html" title="class in javax.xml.soap"><span class="typeNameLink">Prev Class</span></a></li> |
| <li><a href="../../../javax/xml/soap/SOAPException.html" title="class in javax.xml.soap"><span class="typeNameLink">Next Class</span></a></li> |
| </ul> |
| <ul class="navList"> |
| <li><a href="../../../index.html?javax/xml/soap/SOAPEnvelope.html" target="_top">Frames</a></li> |
| <li><a href="SOAPEnvelope.html" target="_top">No Frames</a></li> |
| </ul> |
| <ul class="navList" id="allclasses_navbar_top"> |
| <li><a href="../../../allclasses-noframe.html">All Classes</a></li> |
| </ul> |
| <div> |
| <script type="text/javascript"><!-- |
| allClassesLink = document.getElementById("allclasses_navbar_top"); |
| if(window==top) { |
| allClassesLink.style.display = "block"; |
| } |
| else { |
| allClassesLink.style.display = "none"; |
| } |
| //--> |
| </script> |
| </div> |
| <div> |
| <ul class="subNavList"> |
| <li>Summary: </li> |
| <li>Nested | </li> |
| <li>Field | </li> |
| <li>Constr | </li> |
| <li><a href="#method.summary">Method</a></li> |
| </ul> |
| <ul class="subNavList"> |
| <li>Detail: </li> |
| <li>Field | </li> |
| <li>Constr | </li> |
| <li><a href="#method.detail">Method</a></li> |
| </ul> |
| </div> |
| <a name="skip.navbar.top"> |
| <!-- --> |
| </a></div> |
| <!-- ========= END OF TOP NAVBAR ========= --> |
| <!-- ======== START OF CLASS DATA ======== --> |
| <div class="header"> |
| <div class="subTitle">javax.xml.soap</div> |
| <h2 title="Interface SOAPEnvelope" class="title">Interface SOAPEnvelope</h2> |
| </div> |
| <div class="contentContainer"> |
| <div class="description"> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <dl> |
| <dt>All Superinterfaces:</dt> |
| <dd>org.w3c.dom.Element, org.w3c.dom.Node, <a href="../../../javax/xml/soap/SOAPElement.html" title="interface in javax.xml.soap">SOAPElement</a></dd> |
| </dl> |
| <hr> |
| <br> |
| <pre>public interface <span class="typeNameLabel">SOAPEnvelope</span> |
| extends <a href="../../../javax/xml/soap/SOAPElement.html" title="interface in javax.xml.soap">SOAPElement</a></pre> |
| <div class="block">The container for the SOAPHeader and SOAPBody portions of a |
| <code>SOAPPart</code> object. By default, a <code>SOAPMessage</code> |
| object is created with a <code>SOAPPart</code> object that has a |
| <code>SOAPEnvelope</code> object. The <code>SOAPEnvelope</code> object |
| by default has an empty <code>SOAPBody</code> object and an empty |
| <code>SOAPHeader</code> object. The <code>SOAPBody</code> object is |
| required, and the <code>SOAPHeader</code> object, though |
| optional, is used in the majority of cases. If the |
| <code>SOAPHeader</code> object is not needed, it can be deleted, |
| which is shown later. |
| <P> |
| A client can access the <code>SOAPHeader</code> and <code>SOAPBody</code> |
| objects by calling the methods <code>SOAPEnvelope.getHeader</code> and |
| <code>SOAPEnvelope.getBody</code>. The |
| following lines of code use these two methods after starting with |
| the <code>SOAPMessage</code> |
| object <i>message</i> to get the <code>SOAPPart</code> object <i>sp</i>, |
| which is then used to get the <code>SOAPEnvelope</code> object <i>se</i>. |
| |
| <pre><code> |
| SOAPPart sp = message.getSOAPPart(); |
| SOAPEnvelope se = sp.getEnvelope(); |
| SOAPHeader sh = se.getHeader(); |
| SOAPBody sb = se.getBody(); |
| </code></pre> |
| <P> |
| It is possible to change the body or header of a <code>SOAPEnvelope</code> |
| object by retrieving the current one, deleting it, and then adding |
| a new body or header. The <code>javax.xml.soap.Node</code> method |
| <code>deleteNode</code> deletes the XML element (node) on which it is |
| called. For example, the following line of code deletes the |
| <code>SOAPBody</code> object that is retrieved by the method <code>getBody</code>. |
| <pre><code> |
| se.getBody().detachNode(); |
| </code></pre> |
| To create a <code>SOAPHeader</code> object to replace the one that was removed, |
| a client uses |
| the method <code>SOAPEnvelope.addHeader</code>, which creates a new header and |
| adds it to the <code>SOAPEnvelope</code> object. Similarly, the method |
| <code>addBody</code> creates a new <code>SOAPBody</code> object and adds |
| it to the <code>SOAPEnvelope</code> object. The following code fragment |
| retrieves the current header, removes it, and adds a new one. Then |
| it retrieves the current body, removes it, and adds a new one. |
| |
| <pre><code> |
| SOAPPart sp = message.getSOAPPart(); |
| SOAPEnvelope se = sp.getEnvelope(); |
| se.getHeader().detachNode(); |
| SOAPHeader sh = se.addHeader(); |
| se.getBody().detachNode(); |
| SOAPBody sb = se.addBody(); |
| </code></pre> |
| It is an error to add a <code>SOAPBody</code> or <code>SOAPHeader</code> |
| object if one already exists. |
| <P> |
| The <code>SOAPEnvelope</code> interface provides three methods for creating |
| <code>Name</code> objects. One method creates <code>Name</code> objects with |
| a local name, a namespace prefix, and a namesapce URI. The second method creates |
| <code>Name</code> objects with a local name and a namespace prefix, and the third |
| creates <code>Name</code> objects with just a local name. The following line of |
| code, in which <i>se</i> is a <code>SOAPEnvelope</code> object, creates a new |
| <code>Name</code> object with all three. |
| <pre><code> |
| Name name = se.createName("GetLastTradePrice", "WOMBAT", |
| "http://www.wombat.org/trader"); |
| </code></pre></div> |
| <dl> |
| <dt><span class="simpleTagLabel">Since:</span></dt> |
| <dd>1.6</dd> |
| </dl> |
| </li> |
| </ul> |
| </div> |
| <div class="summary"> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <!-- =========== FIELD SUMMARY =========== --> |
| <ul class="blockList"> |
| <li class="blockList"><a name="field.summary"> |
| <!-- --> |
| </a> |
| <h3>Field Summary</h3> |
| <ul class="blockList"> |
| <li class="blockList"><a name="fields.inherited.from.class.org.w3c.dom.Node"> |
| <!-- --> |
| </a> |
| <h3>Fields inherited from interface org.w3c.dom.Node</h3> |
| <code>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</code></li> |
| </ul> |
| </li> |
| </ul> |
| <!-- ========== METHOD SUMMARY =========== --> |
| <ul class="blockList"> |
| <li class="blockList"><a name="method.summary"> |
| <!-- --> |
| </a> |
| <h3>Method Summary</h3> |
| <table class="memberSummary" border="0" cellpadding="3" cellspacing="0" summary="Method Summary table, listing methods, and an explanation"> |
| <caption><span id="t0" class="activeTableTab"><span>All Methods</span><span class="tabEnd"> </span></span><span id="t2" class="tableTab"><span><a href="javascript:show(2);">Instance Methods</a></span><span class="tabEnd"> </span></span><span id="t3" class="tableTab"><span><a href="javascript:show(4);">Abstract Methods</a></span><span class="tabEnd"> </span></span></caption> |
| <tr> |
| <th class="colFirst" scope="col">Modifier and Type</th> |
| <th class="colLast" scope="col">Method and Description</th> |
| </tr> |
| <tr id="i0" class="altColor"> |
| <td class="colFirst"><code><a href="../../../javax/xml/soap/SOAPBody.html" title="interface in javax.xml.soap">SOAPBody</a></code></td> |
| <td class="colLast"><code><span class="memberNameLink"><a href="../../../javax/xml/soap/SOAPEnvelope.html#addBody--">addBody</a></span>()</code> |
| <div class="block">Creates a <code>SOAPBody</code> object and sets it as the |
| <code>SOAPBody</code> object for this <code>SOAPEnvelope</code> |
| object.</div> |
| </td> |
| </tr> |
| <tr id="i1" class="rowColor"> |
| <td class="colFirst"><code><a href="../../../javax/xml/soap/SOAPHeader.html" title="interface in javax.xml.soap">SOAPHeader</a></code></td> |
| <td class="colLast"><code><span class="memberNameLink"><a href="../../../javax/xml/soap/SOAPEnvelope.html#addHeader--">addHeader</a></span>()</code> |
| <div class="block">Creates a <code>SOAPHeader</code> object and sets it as the |
| <code>SOAPHeader</code> object for this <code>SOAPEnvelope</code> |
| object.</div> |
| </td> |
| </tr> |
| <tr id="i2" class="altColor"> |
| <td class="colFirst"><code><a href="../../../javax/xml/soap/Name.html" title="interface in javax.xml.soap">Name</a></code></td> |
| <td class="colLast"><code><span class="memberNameLink"><a href="../../../javax/xml/soap/SOAPEnvelope.html#createName-java.lang.String-">createName</a></span>(java.lang.String localName)</code> |
| <div class="block">Creates a new <code>Name</code> object initialized with the |
| given local name.</div> |
| </td> |
| </tr> |
| <tr id="i3" class="rowColor"> |
| <td class="colFirst"><code><a href="../../../javax/xml/soap/Name.html" title="interface in javax.xml.soap">Name</a></code></td> |
| <td class="colLast"><code><span class="memberNameLink"><a href="../../../javax/xml/soap/SOAPEnvelope.html#createName-java.lang.String-java.lang.String-java.lang.String-">createName</a></span>(java.lang.String localName, |
| java.lang.String prefix, |
| java.lang.String uri)</code> |
| <div class="block">Creates a new <code>Name</code> object initialized with the |
| given local name, namespace prefix, and namespace URI.</div> |
| </td> |
| </tr> |
| <tr id="i4" class="altColor"> |
| <td class="colFirst"><code><a href="../../../javax/xml/soap/SOAPBody.html" title="interface in javax.xml.soap">SOAPBody</a></code></td> |
| <td class="colLast"><code><span class="memberNameLink"><a href="../../../javax/xml/soap/SOAPEnvelope.html#getBody--">getBody</a></span>()</code> |
| <div class="block">Returns the <code>SOAPBody</code> object associated with this |
| <code>SOAPEnvelope</code> object.</div> |
| </td> |
| </tr> |
| <tr id="i5" class="rowColor"> |
| <td class="colFirst"><code><a href="../../../javax/xml/soap/SOAPHeader.html" title="interface in javax.xml.soap">SOAPHeader</a></code></td> |
| <td class="colLast"><code><span class="memberNameLink"><a href="../../../javax/xml/soap/SOAPEnvelope.html#getHeader--">getHeader</a></span>()</code> |
| <div class="block">Returns the <code>SOAPHeader</code> object for |
| this <code>SOAPEnvelope</code> object.</div> |
| </td> |
| </tr> |
| </table> |
| <ul class="blockList"> |
| <li class="blockList"><a name="methods.inherited.from.class.javax.xml.soap.SOAPElement"> |
| <!-- --> |
| </a> |
| <h3>Methods inherited from interface javax.xml.soap.<a href="../../../javax/xml/soap/SOAPElement.html" title="interface in javax.xml.soap">SOAPElement</a></h3> |
| <code><a href="../../../javax/xml/soap/SOAPElement.html#addAttribute-javax.xml.soap.Name-java.lang.String-">addAttribute</a>, <a href="../../../javax/xml/soap/SOAPElement.html#addAttribute-javax.xml.namespace.QName-java.lang.String-">addAttribute</a>, <a href="../../../javax/xml/soap/SOAPElement.html#addChildElement-javax.xml.soap.Name-">addChildElement</a>, <a href="../../../javax/xml/soap/SOAPElement.html#addChildElement-javax.xml.namespace.QName-">addChildElement</a>, <a href="../../../javax/xml/soap/SOAPElement.html#addChildElement-javax.xml.soap.SOAPElement-">addChildElement</a>, <a href="../../../javax/xml/soap/SOAPElement.html#addChildElement-java.lang.String-">addChildElement</a>, <a href="../../../javax/xml/soap/SOAPElement.html#addChildElement-java.lang.String-java.lang.String-">addChildElement</a>, <a href="../../../javax/xml/soap/SOAPElement.html#addChildElement-java.lang.String-java.lang.String-java.lang.String-">addChildElement</a>, <a href="../../../javax/xml/soap/SOAPElement.html#addNamespaceDeclaration-java.lang.String-java.lang.String-">addNamespaceDeclaration</a>, <a href="../../../javax/xml/soap/SOAPElement.html#addTextNode-java.lang.String-">addTextNode</a>, <a href="../../../javax/xml/soap/SOAPElement.html#createQName-java.lang.String-java.lang.String-">createQName</a>, <a href="../../../javax/xml/soap/SOAPElement.html#getAllAttributes--">getAllAttributes</a>, <a href="../../../javax/xml/soap/SOAPElement.html#getAllAttributesAsQNames--">getAllAttributesAsQNames</a>, <a href="../../../javax/xml/soap/SOAPElement.html#getAttributeValue-javax.xml.soap.Name-">getAttributeValue</a>, <a href="../../../javax/xml/soap/SOAPElement.html#getAttributeValue-javax.xml.namespace.QName-">getAttributeValue</a>, <a href="../../../javax/xml/soap/SOAPElement.html#getChildElements--">getChildElements</a>, <a href="../../../javax/xml/soap/SOAPElement.html#getChildElements-javax.xml.soap.Name-">getChildElements</a>, <a href="../../../javax/xml/soap/SOAPElement.html#getChildElements-javax.xml.namespace.QName-">getChildElements</a>, <a href="../../../javax/xml/soap/SOAPElement.html#getElementName--">getElementName</a>, <a href="../../../javax/xml/soap/SOAPElement.html#getElementQName--">getElementQName</a>, <a href="../../../javax/xml/soap/SOAPElement.html#getEncodingStyle--">getEncodingStyle</a>, <a href="../../../javax/xml/soap/SOAPElement.html#getNamespacePrefixes--">getNamespacePrefixes</a>, <a href="../../../javax/xml/soap/SOAPElement.html#getNamespaceURI-java.lang.String-">getNamespaceURI</a>, <a href="../../../javax/xml/soap/SOAPElement.html#getVisibleNamespacePrefixes--">getVisibleNamespacePrefixes</a>, <a href="../../../javax/xml/soap/SOAPElement.html#removeAttribute-javax.xml.soap.Name-">removeAttribute</a>, <a href="../../../javax/xml/soap/SOAPElement.html#removeAttribute-javax.xml.namespace.QName-">removeAttribute</a>, <a href="../../../javax/xml/soap/SOAPElement.html#removeContents--">removeContents</a>, <a href="../../../javax/xml/soap/SOAPElement.html#removeNamespaceDeclaration-java.lang.String-">removeNamespaceDeclaration</a>, <a href="../../../javax/xml/soap/SOAPElement.html#setElementQName-javax.xml.namespace.QName-">setElementQName</a>, <a href="../../../javax/xml/soap/SOAPElement.html#setEncodingStyle-java.lang.String-">setEncodingStyle</a></code></li> |
| </ul> |
| <ul class="blockList"> |
| <li class="blockList"><a name="methods.inherited.from.class.javax.xml.soap.Node"> |
| <!-- --> |
| </a> |
| <h3>Methods inherited from interface javax.xml.soap.<a href="../../../javax/xml/soap/Node.html" title="interface in javax.xml.soap">Node</a></h3> |
| <code><a href="../../../javax/xml/soap/Node.html#detachNode--">detachNode</a>, <a href="../../../javax/xml/soap/Node.html#getParentElement--">getParentElement</a>, <a href="../../../javax/xml/soap/Node.html#getValue--">getValue</a>, <a href="../../../javax/xml/soap/Node.html#recycleNode--">recycleNode</a>, <a href="../../../javax/xml/soap/Node.html#setParentElement-javax.xml.soap.SOAPElement-">setParentElement</a>, <a href="../../../javax/xml/soap/Node.html#setValue-java.lang.String-">setValue</a></code></li> |
| </ul> |
| <ul class="blockList"> |
| <li class="blockList"><a name="methods.inherited.from.class.org.w3c.dom.Element"> |
| <!-- --> |
| </a> |
| <h3>Methods inherited from interface org.w3c.dom.Element</h3> |
| <code>getAttribute, getAttributeNode, getAttributeNodeNS, getAttributeNS, getElementsByTagName, getElementsByTagNameNS, getSchemaTypeInfo, getTagName, hasAttribute, hasAttributeNS, removeAttribute, removeAttributeNode, removeAttributeNS, setAttribute, setAttributeNode, setAttributeNodeNS, setAttributeNS, setIdAttribute, setIdAttributeNode, setIdAttributeNS</code></li> |
| </ul> |
| <ul class="blockList"> |
| <li class="blockList"><a name="methods.inherited.from.class.org.w3c.dom.Node"> |
| <!-- --> |
| </a> |
| <h3>Methods inherited from interface org.w3c.dom.Node</h3> |
| <code>appendChild, cloneNode, compareDocumentPosition, getAttributes, getBaseURI, getChildNodes, getFeature, getFirstChild, getLastChild, getLocalName, getNamespaceURI, getNextSibling, getNodeName, getNodeType, getNodeValue, getOwnerDocument, getParentNode, getPrefix, getPreviousSibling, getTextContent, getUserData, hasAttributes, hasChildNodes, insertBefore, isDefaultNamespace, isEqualNode, isSameNode, isSupported, lookupNamespaceURI, lookupPrefix, normalize, removeChild, replaceChild, setNodeValue, setPrefix, setTextContent, setUserData</code></li> |
| </ul> |
| </li> |
| </ul> |
| </li> |
| </ul> |
| </div> |
| <div class="details"> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <!-- ============ METHOD DETAIL ========== --> |
| <ul class="blockList"> |
| <li class="blockList"><a name="method.detail"> |
| <!-- --> |
| </a> |
| <h3>Method Detail</h3> |
| <a name="createName-java.lang.String-java.lang.String-java.lang.String-"> |
| <!-- --> |
| </a> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <h4>createName</h4> |
| <pre><a href="../../../javax/xml/soap/Name.html" title="interface in javax.xml.soap">Name</a> createName(java.lang.String localName, |
| java.lang.String prefix, |
| java.lang.String uri) |
| throws <a href="../../../javax/xml/soap/SOAPException.html" title="class in javax.xml.soap">SOAPException</a></pre> |
| <div class="block">Creates a new <code>Name</code> object initialized with the |
| given local name, namespace prefix, and namespace URI. |
| <P> |
| This factory method creates <code>Name</code> objects for use in |
| the SOAP/XML document.</div> |
| <dl> |
| <dt><span class="paramLabel">Parameters:</span></dt> |
| <dd><code>localName</code> - a <code>String</code> giving the local name</dd> |
| <dd><code>prefix</code> - a <code>String</code> giving the prefix of the namespace</dd> |
| <dd><code>uri</code> - a <code>String</code> giving the URI of the namespace</dd> |
| <dt><span class="returnLabel">Returns:</span></dt> |
| <dd>a <code>Name</code> object initialized with the given |
| local name, namespace prefix, and namespace URI</dd> |
| <dt><span class="throwsLabel">Throws:</span></dt> |
| <dd><code><a href="../../../javax/xml/soap/SOAPException.html" title="class in javax.xml.soap">SOAPException</a></code> - if there is a SOAP error</dd> |
| </dl> |
| </li> |
| </ul> |
| <a name="createName-java.lang.String-"> |
| <!-- --> |
| </a> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <h4>createName</h4> |
| <pre><a href="../../../javax/xml/soap/Name.html" title="interface in javax.xml.soap">Name</a> createName(java.lang.String localName) |
| throws <a href="../../../javax/xml/soap/SOAPException.html" title="class in javax.xml.soap">SOAPException</a></pre> |
| <div class="block">Creates a new <code>Name</code> object initialized with the |
| given local name. |
| <P> |
| This factory method creates <code>Name</code> objects for use in |
| the SOAP/XML document.</div> |
| <dl> |
| <dt><span class="paramLabel">Parameters:</span></dt> |
| <dd><code>localName</code> - a <code>String</code> giving the local name</dd> |
| <dt><span class="returnLabel">Returns:</span></dt> |
| <dd>a <code>Name</code> object initialized with the given |
| local name</dd> |
| <dt><span class="throwsLabel">Throws:</span></dt> |
| <dd><code><a href="../../../javax/xml/soap/SOAPException.html" title="class in javax.xml.soap">SOAPException</a></code> - if there is a SOAP error</dd> |
| </dl> |
| </li> |
| </ul> |
| <a name="getHeader--"> |
| <!-- --> |
| </a> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <h4>getHeader</h4> |
| <pre><a href="../../../javax/xml/soap/SOAPHeader.html" title="interface in javax.xml.soap">SOAPHeader</a> getHeader() |
| throws <a href="../../../javax/xml/soap/SOAPException.html" title="class in javax.xml.soap">SOAPException</a></pre> |
| <div class="block">Returns the <code>SOAPHeader</code> object for |
| this <code>SOAPEnvelope</code> object. |
| <P> |
| A new <code>SOAPMessage</code> object is by default created with a |
| <code>SOAPEnvelope</code> object that contains an empty |
| <code>SOAPHeader</code> object. As a result, the method |
| <code>getHeader</code> will always return a <code>SOAPHeader</code> |
| object unless the header has been removed and a new one has not |
| been added.</div> |
| <dl> |
| <dt><span class="returnLabel">Returns:</span></dt> |
| <dd>the <code>SOAPHeader</code> object or <code>null</code> if |
| there is none</dd> |
| <dt><span class="throwsLabel">Throws:</span></dt> |
| <dd><code><a href="../../../javax/xml/soap/SOAPException.html" title="class in javax.xml.soap">SOAPException</a></code> - if there is a problem obtaining the |
| <code>SOAPHeader</code> object</dd> |
| </dl> |
| </li> |
| </ul> |
| <a name="getBody--"> |
| <!-- --> |
| </a> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <h4>getBody</h4> |
| <pre><a href="../../../javax/xml/soap/SOAPBody.html" title="interface in javax.xml.soap">SOAPBody</a> getBody() |
| throws <a href="../../../javax/xml/soap/SOAPException.html" title="class in javax.xml.soap">SOAPException</a></pre> |
| <div class="block">Returns the <code>SOAPBody</code> object associated with this |
| <code>SOAPEnvelope</code> object. |
| <P> |
| A new <code>SOAPMessage</code> object is by default created with a |
| <code>SOAPEnvelope</code> object that contains an empty |
| <code>SOAPBody</code> object. As a result, the method |
| <code>getBody</code> will always return a <code>SOAPBody</code> |
| object unless the body has been removed and a new one has not |
| been added.</div> |
| <dl> |
| <dt><span class="returnLabel">Returns:</span></dt> |
| <dd>the <code>SOAPBody</code> object for this |
| <code>SOAPEnvelope</code> object or <code>null</code> |
| if there is none</dd> |
| <dt><span class="throwsLabel">Throws:</span></dt> |
| <dd><code><a href="../../../javax/xml/soap/SOAPException.html" title="class in javax.xml.soap">SOAPException</a></code> - if there is a problem obtaining the |
| <code>SOAPBody</code> object</dd> |
| </dl> |
| </li> |
| </ul> |
| <a name="addHeader--"> |
| <!-- --> |
| </a> |
| <ul class="blockList"> |
| <li class="blockList"> |
| <h4>addHeader</h4> |
| <pre><a href="../../../javax/xml/soap/SOAPHeader.html" title="interface in javax.xml.soap">SOAPHeader</a> addHeader() |
| throws <a href="../../../javax/xml/soap/SOAPException.html" title="class in javax.xml.soap">SOAPException</a></pre> |
| <div class="block">Creates a <code>SOAPHeader</code> object and sets it as the |
| <code>SOAPHeader</code> object for this <code>SOAPEnvelope</code> |
| object. |
| <P> |
| It is illegal to add a header when the envelope already |
| contains a header. Therefore, this method should be called |
| only after the existing header has been removed.</div> |
| <dl> |
| <dt><span class="returnLabel">Returns:</span></dt> |
| <dd>the new <code>SOAPHeader</code> object</dd> |
| <dt><span class="throwsLabel">Throws:</span></dt> |
| <dd><code><a href="../../../javax/xml/soap/SOAPException.html" title="class in javax.xml.soap">SOAPException</a></code> - if this |
| <code>SOAPEnvelope</code> object already contains a |
| valid <code>SOAPHeader</code> object</dd> |
| </dl> |
| </li> |
| </ul> |
| <a name="addBody--"> |
| <!-- --> |
| </a> |
| <ul class="blockListLast"> |
| <li class="blockList"> |
| <h4>addBody</h4> |
| <pre><a href="../../../javax/xml/soap/SOAPBody.html" title="interface in javax.xml.soap">SOAPBody</a> addBody() |
| throws <a href="../../../javax/xml/soap/SOAPException.html" title="class in javax.xml.soap">SOAPException</a></pre> |
| <div class="block">Creates a <code>SOAPBody</code> object and sets it as the |
| <code>SOAPBody</code> object for this <code>SOAPEnvelope</code> |
| object. |
| <P> |
| It is illegal to add a body when the envelope already |
| contains a body. Therefore, this method should be called |
| only after the existing body has been removed.</div> |
| <dl> |
| <dt><span class="returnLabel">Returns:</span></dt> |
| <dd>the new <code>SOAPBody</code> object</dd> |
| <dt><span class="throwsLabel">Throws:</span></dt> |
| <dd><code><a href="../../../javax/xml/soap/SOAPException.html" title="class in javax.xml.soap">SOAPException</a></code> - if this |
| <code>SOAPEnvelope</code> object already contains a |
| valid <code>SOAPBody</code> object</dd> |
| </dl> |
| </li> |
| </ul> |
| </li> |
| </ul> |
| </li> |
| </ul> |
| </div> |
| </div> |
| <!-- ========= END OF CLASS DATA ========= --> |
| <!-- ======= START OF BOTTOM NAVBAR ====== --> |
| <div class="bottomNav"><a name="navbar.bottom"> |
| <!-- --> |
| </a> |
| <div class="skipNav"><a href="#skip.navbar.bottom" title="Skip navigation links">Skip navigation links</a></div> |
| <a name="navbar.bottom.firstrow"> |
| <!-- --> |
| </a> |
| <ul class="navList" title="Navigation"> |
| <li><a href="../../../overview-summary.html">Overview</a></li> |
| <li><a href="package-summary.html">Package</a></li> |
| <li class="navBarCell1Rev">Class</li> |
| <li><a href="package-tree.html">Tree</a></li> |
| <li><a href="../../../deprecated-list.html">Deprecated</a></li> |
| <li><a href="../../../index-all.html">Index</a></li> |
| <li><a href="../../../help-doc.html">Help</a></li> |
| </ul> |
| </div> |
| <div class="subNav"> |
| <ul class="navList"> |
| <li><a href="../../../javax/xml/soap/SOAPElementFactory.html" title="class in javax.xml.soap"><span class="typeNameLink">Prev Class</span></a></li> |
| <li><a href="../../../javax/xml/soap/SOAPException.html" title="class in javax.xml.soap"><span class="typeNameLink">Next Class</span></a></li> |
| </ul> |
| <ul class="navList"> |
| <li><a href="../../../index.html?javax/xml/soap/SOAPEnvelope.html" target="_top">Frames</a></li> |
| <li><a href="SOAPEnvelope.html" target="_top">No Frames</a></li> |
| </ul> |
| <ul class="navList" id="allclasses_navbar_bottom"> |
| <li><a href="../../../allclasses-noframe.html">All Classes</a></li> |
| </ul> |
| <div> |
| <script type="text/javascript"><!-- |
| allClassesLink = document.getElementById("allclasses_navbar_bottom"); |
| if(window==top) { |
| allClassesLink.style.display = "block"; |
| } |
| else { |
| allClassesLink.style.display = "none"; |
| } |
| //--> |
| </script> |
| </div> |
| <div> |
| <ul class="subNavList"> |
| <li>Summary: </li> |
| <li>Nested | </li> |
| <li>Field | </li> |
| <li>Constr | </li> |
| <li><a href="#method.summary">Method</a></li> |
| </ul> |
| <ul class="subNavList"> |
| <li>Detail: </li> |
| <li>Field | </li> |
| <li>Constr | </li> |
| <li><a href="#method.detail">Method</a></li> |
| </ul> |
| </div> |
| <a name="skip.navbar.bottom"> |
| <!-- --> |
| </a></div> |
| <!-- ======== END OF BOTTOM NAVBAR ======= --> |
| </body> |
| </html> |