Name
SOAPFaultElement
Synopsis
public interface SOAPFaultElement extends SOAPElement { }
SOAPFaultElement
is a subinterface of
SOAPElement
that represents an element that has
been added directly to a SOAPFault
. In all other
respects, a SOAPFaultElement
is the same as a
SOAPElement
. The Detail
element, described earlier in this chapter, is an example of a
SOAPFaultElement
that can be created using the
addDetail( )
method of the
SOAPFault
interface. There are two other ways to
create a SOAPFaultElement
:
Using the
addChildElement( )
method thatSOAPFault
inherits fromSOAPElement
. For example,fault.addChildElement("BookError", "books"
, "urn:BookService")
creates and returns aSOAPFaultElement
calledBookError
in the namespaceurn:BookService
, and also adds it to theSOAPFault
element referenced by the variablefault
.Creating a
SOAPElement
using the methods ofSOAPFactory
orSOAPElementFactory
and usingaddChildElement( )
to add it to aSOAPFault
. In this case, theSOAPElement
is replaced by an equivalentSOAPFaultElement
, and any nested elements are copied.
Implementations
Detail
Get Java Web Services in a Nutshell now with the O’Reilly learning platform.
O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.