public class DomPoxMessage extends Object implements PoxMessage
PoxMessage interface that is based on a DOM Document.Document| Constructor and Description |
|---|
DomPoxMessage(Document document,
Transformer transformer,
String contentType)
Constructs a new instance of the
DomPoxMessage with the given document. |
| Modifier and Type | Method and Description |
|---|---|
Document |
getDocument()
Returns the document underlying this message.
|
String |
getFaultReason() |
Result |
getPayloadResult()
Returns the contents of the message as a
Result. |
Source |
getPayloadSource()
Returns the contents of the message as a
Source. |
boolean |
hasFault() |
String |
toString() |
void |
writeTo(OutputStream outputStream)
Writes the entire message to the given output stream.
|
public DomPoxMessage(Document document, Transformer transformer, String contentType)
DomPoxMessage with the given document.document - the document to base the message onpublic Document getDocument()
public Result getPayloadResult()
WebServiceMessageResult.
Calling this method removes the current payload.
Implementations that are read-only will throw an UnsupportedOperationException.
getPayloadResult in interface WebServiceMessagepublic Source getPayloadSource()
WebServiceMessageSource.
Depending on the implementation, this can be retrieved multiple times, or just a single time.
getPayloadSource in interface WebServiceMessagepublic boolean hasFault()
public String getFaultReason()
public void writeTo(OutputStream outputStream) throws IOException
WebServiceMessageIf the given stream is an instance of TransportOutputStream, the corresponding headers will be written as well.
writeTo in interface WebServiceMessageoutputStream - the stream to write toIOException - if an I/O exception occurs