Interface MessageContext
-
- All Superinterfaces:
DistributedPropertySet,PropertySet
- All Known Implementing Classes:
Packet
public interface MessageContext extends DistributedPropertySet
MessageContext represents a container of a SOAP message and all the properties including the transport headers. MessageContext is a compositePropertySetthat combines properties exposed from multiplePropertySets into one.This implementation allows one
PropertySetto assemble all properties exposed from other "satellite"PropertySets. (A satellite may itself be aDistributedPropertySet, so in general this can form a tree.)- Author:
- shih-chang.chen@oracle.com
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from interface com.oracle.webservices.api.message.PropertySet
PropertySet.Property
-
-
Method Summary
All Methods Instance Methods Abstract Methods Deprecated Methods Modifier and Type Method Description javax.xml.soap.SOAPMessagegetAsSOAPMessage()Gets the SAAJ SOAPMessage representation of the SOAP message.ContentTypegetContentType()Gets the Content-type of this message.javax.xml.soap.SOAPMessagegetSOAPMessage()Deprecated.use getAsSOAPMessageContentTypewriteTo(OutputStream out)Writes the XML infoset portion of this MessageContext (from <soap:Envelope> to </soap:Envelope>).-
Methods inherited from interface com.oracle.webservices.api.message.DistributedPropertySet
addSatellite, addSatellite, copySatelliteInto, getSatellite, getSatellites, removeSatellite
-
Methods inherited from interface com.oracle.webservices.api.message.PropertySet
asMap, containsKey, createMapView, get, put, remove, supports
-
-
-
-
Method Detail
-
getAsSOAPMessage
javax.xml.soap.SOAPMessage getAsSOAPMessage() throws javax.xml.soap.SOAPExceptionGets the SAAJ SOAPMessage representation of the SOAP message.- Returns:
- The SOAPMessage
- Throws:
javax.xml.soap.SOAPException
-
getSOAPMessage
javax.xml.soap.SOAPMessage getSOAPMessage() throws javax.xml.soap.SOAPExceptionDeprecated.use getAsSOAPMessageGets the SAAJ SOAPMessage representation of the SOAP message.- Returns:
- The SOAPMessage
- Throws:
javax.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 aOutputStreamthrowsIOException.
-
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
-
-