soapbody.html

来自「j2ee api,很好的api。我这现在有」· HTML 代码 · 共 517 行 · 第 1/3 页

HTML
517
字号
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE>&nbsp;<A HREF="../../../javax/xml/soap/SOAPFault.html" title="interface in javax.xml.soap">SOAPFault</A></CODE></FONT></TD><TD><CODE><B><A HREF="../../../javax/xml/soap/SOAPBody.html#addFault(javax.xml.soap.Name, java.lang.String)">addFault</A></B>(<A HREF="../../../javax/xml/soap/Name.html" title="interface in javax.xml.soap">Name</A>&nbsp;faultCode,         <A HREF="http://java.sun.com/j2se/1.4/docs/api/java/lang/String.html" title="class or interface in java.lang">String</A>&nbsp;faultString)</CODE><BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Creates a new <code>SOAPFault</code> object and adds it to this <code>SOAPBody</code> object. </TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE>&nbsp;<A HREF="../../../javax/xml/soap/SOAPFault.html" title="interface in javax.xml.soap">SOAPFault</A></CODE></FONT></TD><TD><CODE><B><A HREF="../../../javax/xml/soap/SOAPBody.html#addFault(javax.xml.soap.Name, java.lang.String, java.util.Locale)">addFault</A></B>(<A HREF="../../../javax/xml/soap/Name.html" title="interface in javax.xml.soap">Name</A>&nbsp;faultCode,         <A HREF="http://java.sun.com/j2se/1.4/docs/api/java/lang/String.html" title="class or interface in java.lang">String</A>&nbsp;faultString,         <A HREF="http://java.sun.com/j2se/1.4/docs/api/java/util/Locale.html" title="class or interface in java.util">Locale</A>&nbsp;locale)</CODE><BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Creates a new <code>SOAPFault</code> object and adds it to this <code>SOAPBody</code> object. </TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE>&nbsp;<A HREF="../../../javax/xml/soap/SOAPFault.html" title="interface in javax.xml.soap">SOAPFault</A></CODE></FONT></TD><TD><CODE><B><A HREF="../../../javax/xml/soap/SOAPBody.html#getFault()">getFault</A></B>()</CODE><BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Returns the <code>SOAPFault</code> object in this <code>SOAPBody</code> object.</TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE>&nbsp;boolean</CODE></FONT></TD><TD><CODE><B><A HREF="../../../javax/xml/soap/SOAPBody.html#hasFault()">hasFault</A></B>()</CODE><BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Indicates whether a <code>SOAPFault</code> object exists in this <code>SOAPBody</code> object.</TD></TR></TABLE>&nbsp;<A NAME="methods_inherited_from_class_javax.xml.soap.SOAPElement"><!-- --></A><TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY=""><TR BGCOLOR="#EEEEFF" CLASS="TableSubHeadingColor"><TD><B>Methods inherited from interface javax.xml.soap.<A HREF="../../../javax/xml/soap/SOAPElement.html" title="interface in javax.xml.soap">SOAPElement</A></B></TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD><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#addChildElement(javax.xml.soap.Name)">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#getAllAttributes()">getAllAttributes</A>, <A HREF="../../../javax/xml/soap/SOAPElement.html#getAttributeValue(javax.xml.soap.Name)">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#getElementName()">getElementName</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#removeContents()">removeContents</A>, <A HREF="../../../javax/xml/soap/SOAPElement.html#removeNamespaceDeclaration(java.lang.String)">removeNamespaceDeclaration</A>, <A HREF="../../../javax/xml/soap/SOAPElement.html#setEncodingStyle(java.lang.String)">setEncodingStyle</A></CODE></TD></TR></TABLE>&nbsp;<A NAME="methods_inherited_from_class_javax.xml.soap.Node"><!-- --></A><TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY=""><TR BGCOLOR="#EEEEFF" CLASS="TableSubHeadingColor"><TD><B>Methods inherited from interface javax.xml.soap.<A HREF="../../../javax/xml/soap/Node.html" title="interface in javax.xml.soap">Node</A></B></TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD><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></TD></TR></TABLE>&nbsp;<A NAME="methods_inherited_from_class_org.w3c.dom.Node"><!-- --></A><TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY=""><TR BGCOLOR="#EEEEFF" CLASS="TableSubHeadingColor"><TD><B>Methods inherited from interface org.w3c.dom.<A HREF="http://java.sun.com/j2se/1.4/docs/api/org/w3c/dom/Node.html" title="class or interface in org.w3c.dom">Node</A></B></TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD><CODE><A HREF="http://java.sun.com/j2se/1.4/docs/api/org/w3c/dom/Node.html#appendChild(org.w3c.dom.Node)" title="class or interface in org.w3c.dom">appendChild</A>, <A HREF="http://java.sun.com/j2se/1.4/docs/api/org/w3c/dom/Node.html#cloneNode(boolean)" title="class or interface in org.w3c.dom">cloneNode</A>, <A HREF="http://java.sun.com/j2se/1.4/docs/api/org/w3c/dom/Node.html#getAttributes()" title="class or interface in org.w3c.dom">getAttributes</A>, <A HREF="http://java.sun.com/j2se/1.4/docs/api/org/w3c/dom/Node.html#getChildNodes()" title="class or interface in org.w3c.dom">getChildNodes</A>, <A HREF="http://java.sun.com/j2se/1.4/docs/api/org/w3c/dom/Node.html#getFirstChild()" title="class or interface in org.w3c.dom">getFirstChild</A>, <A HREF="http://java.sun.com/j2se/1.4/docs/api/org/w3c/dom/Node.html#getLastChild()" title="class or interface in org.w3c.dom">getLastChild</A>, <A HREF="http://java.sun.com/j2se/1.4/docs/api/org/w3c/dom/Node.html#getLocalName()" title="class or interface in org.w3c.dom">getLocalName</A>, <A HREF="http://java.sun.com/j2se/1.4/docs/api/org/w3c/dom/Node.html#getNamespaceURI()" title="class or interface in org.w3c.dom">getNamespaceURI</A>, <A HREF="http://java.sun.com/j2se/1.4/docs/api/org/w3c/dom/Node.html#getNextSibling()" title="class or interface in org.w3c.dom">getNextSibling</A>, <A HREF="http://java.sun.com/j2se/1.4/docs/api/org/w3c/dom/Node.html#getNodeName()" title="class or interface in org.w3c.dom">getNodeName</A>, <A HREF="http://java.sun.com/j2se/1.4/docs/api/org/w3c/dom/Node.html#getNodeType()" title="class or interface in org.w3c.dom">getNodeType</A>, <A HREF="http://java.sun.com/j2se/1.4/docs/api/org/w3c/dom/Node.html#getNodeValue()" title="class or interface in org.w3c.dom">getNodeValue</A>, <A HREF="http://java.sun.com/j2se/1.4/docs/api/org/w3c/dom/Node.html#getOwnerDocument()" title="class or interface in org.w3c.dom">getOwnerDocument</A>, <A HREF="http://java.sun.com/j2se/1.4/docs/api/org/w3c/dom/Node.html#getParentNode()" title="class or interface in org.w3c.dom">getParentNode</A>, <A HREF="http://java.sun.com/j2se/1.4/docs/api/org/w3c/dom/Node.html#getPrefix()" title="class or interface in org.w3c.dom">getPrefix</A>, <A HREF="http://java.sun.com/j2se/1.4/docs/api/org/w3c/dom/Node.html#getPreviousSibling()" title="class or interface in org.w3c.dom">getPreviousSibling</A>, <A HREF="http://java.sun.com/j2se/1.4/docs/api/org/w3c/dom/Node.html#hasAttributes()" title="class or interface in org.w3c.dom">hasAttributes</A>, <A HREF="http://java.sun.com/j2se/1.4/docs/api/org/w3c/dom/Node.html#hasChildNodes()" title="class or interface in org.w3c.dom">hasChildNodes</A>, <A HREF="http://java.sun.com/j2se/1.4/docs/api/org/w3c/dom/Node.html#insertBefore(org.w3c.dom.Node, org.w3c.dom.Node)" title="class or interface in org.w3c.dom">insertBefore</A>, <A HREF="http://java.sun.com/j2se/1.4/docs/api/org/w3c/dom/Node.html#isSupported(java.lang.String, java.lang.String)" title="class or interface in org.w3c.dom">isSupported</A>, <A HREF="http://java.sun.com/j2se/1.4/docs/api/org/w3c/dom/Node.html#normalize()" title="class or interface in org.w3c.dom">normalize</A>, <A HREF="http://java.sun.com/j2se/1.4/docs/api/org/w3c/dom/Node.html#removeChild(org.w3c.dom.Node)" title="class or interface in org.w3c.dom">removeChild</A>, <A HREF="http://java.sun.com/j2se/1.4/docs/api/org/w3c/dom/Node.html#replaceChild(org.w3c.dom.Node, org.w3c.dom.Node)" title="class or interface in org.w3c.dom">replaceChild</A>, <A HREF="http://java.sun.com/j2se/1.4/docs/api/org/w3c/dom/Node.html#setNodeValue(java.lang.String)" title="class or interface in org.w3c.dom">setNodeValue</A>, <A HREF="http://java.sun.com/j2se/1.4/docs/api/org/w3c/dom/Node.html#setPrefix(java.lang.String)" title="class or interface in org.w3c.dom">setPrefix</A></CODE></TD></TR></TABLE>&nbsp;<A NAME="methods_inherited_from_class_org.w3c.dom.Element"><!-- --></A><TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY=""><TR BGCOLOR="#EEEEFF" CLASS="TableSubHeadingColor"><TD><B>Methods inherited from interface org.w3c.dom.<A HREF="http://java.sun.com/j2se/1.4/docs/api/org/w3c/dom/Element.html" title="class or interface in org.w3c.dom">Element</A></B></TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD><CODE><A HREF="http://java.sun.com/j2se/1.4/docs/api/org/w3c/dom/Element.html#getAttribute(java.lang.String)" title="class or interface in org.w3c.dom">getAttribute</A>, <A HREF="http://java.sun.com/j2se/1.4/docs/api/org/w3c/dom/Element.html#getAttributeNode(java.lang.String)" title="class or interface in org.w3c.dom">getAttributeNode</A>, <A HREF="http://java.sun.com/j2se/1.4/docs/api/org/w3c/dom/Element.html#getAttributeNodeNS(java.lang.String, java.lang.String)" title="class or interface in org.w3c.dom">getAttributeNodeNS</A>, <A HREF="http://java.sun.com/j2se/1.4/docs/api/org/w3c/dom/Element.html#getAttributeNS(java.lang.String, java.lang.String)" title="class or interface in org.w3c.dom">getAttributeNS</A>, <A HREF="http://java.sun.com/j2se/1.4/docs/api/org/w3c/dom/Element.html#getElementsByTagName(java.lang.String)" title="class or interface in org.w3c.dom">getElementsByTagName</A>, <A HREF="http://java.sun.com/j2se/1.4/docs/api/org/w3c/dom/Element.html#getElementsByTagNameNS(java.lang.String, java.lang.String)" title="class or interface in org.w3c.dom">getElementsByTagNameNS</A>, <A HREF="http://java.sun.com/j2se/1.4/docs/api/org/w3c/dom/Element.html#getTagName()" title="class or interface in org.w3c.dom">getTagName</A>, <A HREF="http://java.sun.com/j2se/1.4/docs/api/org/w3c/dom/Element.html#hasAttribute(java.lang.String)" title="class or interface in org.w3c.dom">hasAttribute</A>, <A HREF="http://java.sun.com/j2se/1.4/docs/api/org/w3c/dom/Element.html#hasAttributeNS(java.lang.String, java.lang.String)" title="class or interface in org.w3c.dom">hasAttributeNS</A>, <A HREF="http://java.sun.com/j2se/1.4/docs/api/org/w3c/dom/Element.html#removeAttribute(java.lang.String)" title="class or interface in org.w3c.dom">removeAttribute</A>, <A HREF="http://java.sun.com/j2se/1.4/docs/api/org/w3c/dom/Element.html#removeAttributeNode(org.w3c.dom.Attr)" title="class or interface in org.w3c.dom">removeAttributeNode</A>, <A HREF="http://java.sun.com/j2se/1.4/docs/api/org/w3c/dom/Element.html#removeAttributeNS(java.lang.String, java.lang.String)" title="class or interface in org.w3c.dom">removeAttributeNS</A>, <A HREF="http://java.sun.com/j2se/1.4/docs/api/org/w3c/dom/Element.html#setAttribute(java.lang.String, java.lang.String)" title="class or interface in org.w3c.dom">setAttribute</A>, <A HREF="http://java.sun.com/j2se/1.4/docs/api/org/w3c/dom/Element.html#setAttributeNode(org.w3c.dom.Attr)" title="class or interface in org.w3c.dom">setAttributeNode</A>, <A HREF="http://java.sun.com/j2se/1.4/docs/api/org/w3c/dom/Element.html#setAttributeNodeNS(org.w3c.dom.Attr)" title="class or interface in org.w3c.dom">setAttributeNodeNS</A>, <A HREF="http://java.sun.com/j2se/1.4/docs/api/org/w3c/dom/Element.html#setAttributeNS(java.lang.String, java.lang.String, java.lang.String)" title="class or interface in org.w3c.dom">setAttributeNS</A></CODE></TD></TR></TABLE>&nbsp;<P><!-- ============ FIELD DETAIL =========== --><!-- ========= CONSTRUCTOR DETAIL ======== --><!-- ============ METHOD DETAIL ========== --><A NAME="method_detail"><!-- --></A><TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY=""><TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor"><TD COLSPAN=1><FONT SIZE="+2"><B>Method Detail</B></FONT></TD></TR></TABLE><A NAME="addFault()"><!-- --></A><H3>addFault</H3><PRE>public <A HREF="../../../javax/xml/soap/SOAPFault.html" title="interface in javax.xml.soap">SOAPFault</A> <B>addFault</B>()                   throws <A HREF="../../../javax/xml/soap/SOAPException.html" title="class in javax.xml.soap">SOAPException</A></PRE><DL><DD>Creates a new <code>SOAPFault</code> object and adds it to this <code>SOAPBody</code> object. The new <code>SOAPFault</code> will have default values set for the mandatory child elements  <code>faultcode</code> and <code>faultstring</code>. <p> A <code>SOAPBody</code> may contain at most one <code>SOAPFault</code> child element<P><DD><DL></DL></DD><DD><DL><DT><B>Returns:</B><DD>the new <code>SOAPFault</code> object<DT><B>Throws:</B><DD><CODE><A HREF="../../../javax/xml/soap/SOAPException.html" title="class in javax.xml.soap">SOAPException</A></CODE> - if there is a SOAP error</DL></DD></DL><HR><A NAME="addFault(javax.xml.soap.Name, java.lang.String, java.util.Locale)"><!-- --></A><H3>addFault</H3><PRE>public <A HREF="../../../javax/xml/soap/SOAPFault.html" title="interface in javax.xml.soap">SOAPFault</A> <B>addFault</B>(<A HREF="../../../javax/xml/soap/Name.html" title="interface in javax.xml.soap">Name</A>&nbsp;faultCode,                          <A HREF="http://java.sun.com/j2se/1.4/docs/api/java/lang/String.html" title="class or interface in java.lang">String</A>&nbsp;faultString,                          <A HREF="http://java.sun.com/j2se/1.4/docs/api/java/util/Locale.html" title="class or interface in java.util">Locale</A>&nbsp;locale)                   throws <A HREF="../../../javax/xml/soap/SOAPException.html" title="class in javax.xml.soap">SOAPException</A></PRE><DL><DD>Creates a new <code>SOAPFault</code> object and adds it to this <code>SOAPBody</code> object. The new <code>SOAPFault</code> will have a <code>faultcode</code> element that is set to the  <code>faultCode</code> parameter and a <code>faultstring</code> set to <code>faultString</code> and localized to <code>locale</code>. <p> A <code>SOAPBody</code> may contain at most one <code>SOAPFault</code> child element<P><DD><DL></DL></DD><DD><DL><DT><B>Parameters:</B><DD><CODE>faultCode</CODE> - a <code>Name</code> object giving the fault         code to be set; must be one of the fault codes defined in the SOAP         1.1 specification and of type QName<DD><CODE>faultString</CODE> - a <code>String</code> giving an explanation of         the fault<DD><CODE>locale</CODE> - a <A HREF="http://java.sun.com/j2se/1.4/docs/api/java/lang/util.Locale.html" title="class or interface in java.lang"><CODE>Locale</CODE></A> object indicating         the native language of the <code>faultString</code><DT><B>Returns:</B><DD>the new <code>SOAPFault</code> object<DT><B>Throws:</B><DD><CODE><A HREF="../../../javax/xml/soap/SOAPException.html" title="class in javax.xml.soap">SOAPException</A></CODE> - if there is a SOAP error<DT><B>Since:</B></DT>  <DD>SAAJ 1.2</DD><DT><B>See Also:</B><DD><A HREF="../../../javax/xml/soap/SOAPFault.html#setFaultCode(javax.xml.soap.Name)"><CODE>SOAPFault.setFaultCode(javax.xml.soap.Name)</CODE></A>, <A HREF="../../../javax/xml/soap/SOAPFault.html#setFaultString(java.lang.String)"><CODE>SOAPFault.setFaultString(java.lang.String)</CODE></A></DL></DD></DL><HR><A NAME="addFault(javax.xml.soap.Name, java.lang.String)"><!-- --></A><H3>addFault</H3><PRE>public <A HREF="../../../javax/xml/soap/SOAPFault.html" title="interface in javax.xml.soap">SOAPFault</A> <B>addFault</B>(<A HREF="../../../javax/xml/soap/Name.html" title="interface in javax.xml.soap">Name</A>&nbsp;faultCode,                          <A HREF="http://java.sun.com/j2se/1.4/docs/api/java/lang/String.html" title="class or interface in java.lang">String</A>&nbsp;faultString)                   throws <A HREF="../../../javax/xml/soap/SOAPException.html" title="class in javax.xml.soap">SOAPException</A></PRE><DL><DD>Creates a new <code>SOAPFault</code> object and adds it to this <code>SOAPBody</code> object. The new <code>SOAPFault</code> will have a <code>faultcode</code> element that is set to the  <code>faultCode</code> parameter and a <code>faultstring</code> set to <code>faultString</code>. <p> A <code>SOAPBody</code> may contain at most one <code>SOAPFault</code> child element<P><DD><DL>

⌨️ 快捷键说明

复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?