Interface MessageContext

    • Method Detail

      • getAsSOAPMessage

        jakarta.xml.soap.SOAPMessage getAsSOAPMessage()
                                               throws jakarta.xml.soap.SOAPException
        Gets the SAAJ SOAPMessage representation of the SOAP message.
        Returns:
        The SOAPMessage
        Throws:
        jakarta.xml.soap.SOAPException
      • getSOAPMessage

        jakarta.xml.soap.SOAPMessage getSOAPMessage()
                                             throws jakarta.xml.soap.SOAPException
        Deprecated.
        use getAsSOAPMessage
        Gets the SAAJ SOAPMessage representation of the SOAP message.
        Returns:
        The SOAPMessage
        Throws:
        jakarta.xml.soap.SOAPException
      • writeTo

        ContentType writeTo​(OutputStream out)
                     throws IOException
        Writes the XML infoset portion of this MessageContext (from <soap:Envelope> to </soap:Envelope>).
        Parameters:
        out - Must not be null. The caller is responsible for closing the stream, not the callee.
        Returns:
        The MIME content type of the encoded message (such as "application/xml"). This information is often ncessary by transport.
        Throws:
        IOException - if a OutputStream throws IOException.
      • getContentType

        ContentType getContentType()
        Gets the Content-type of this message. For an out-bound message that this getContentType() method returns a null, the Content-Type can be determined only by calling the writeTo method to write the MessageContext to an OutputStream.
        Returns:
        The MIME content type of this message