blob: 0af146f1a3e4b94c857ceba18092c4f02bceb74b [file] [log] [blame]
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<!-- NewPage -->
<html lang="en">
<head>
<meta http-equiv="Content-Type" content="text/html" charset="UTF-8">
<title>TransportUtils (Apache Axis2)</title>
<link rel="stylesheet" type="text/css" href="../../../../stylesheet.css" title="Style">
</head>
<body>
<script type="text/javascript"><!--
if (location.href.indexOf('is-external=true') == -1) {
parent.document.title="TransportUtils (Apache Axis2)";
}
//-->
</script>
<noscript>
<div>JavaScript is disabled on your browser.</div>
</noscript>
<!-- ========= START OF TOP NAVBAR ======= -->
<div class="topNav"><a name="navbar_top">
<!-- -->
</a><a href="#skip-navbar_top" title="Skip navigation links"></a><a name="navbar_top_firstrow">
<!-- -->
</a>
<ul class="navList" title="Navigation">
<li><a href="../../../../overview-summary.html">Overview</a></li>
<li><a href="package-summary.html">Package</a></li>
<li class="navBarCell1Rev">Class</li>
<li><a href="class-use/TransportUtils.html">Use</a></li>
<li><a href="package-tree.html">Tree</a></li>
<li><a href="../../../../deprecated-list.html">Deprecated</a></li>
<li><a href="../../../../index-all.html">Index</a></li>
<li><a href="../../../../help-doc.html">Help</a></li>
</ul>
</div>
<div class="subNav">
<ul class="navList">
<li><a href="../../../../org/apache/axis2/transport/TransportSender.html" title="interface in org.apache.axis2.transport"><span class="strong">Prev Class</span></a></li>
<li><a href="../../../../org/apache/axis2/transport/UtilsTransportServer.html" title="class in org.apache.axis2.transport"><span class="strong">Next Class</span></a></li>
</ul>
<ul class="navList">
<li><a href="../../../../index.html?org/apache/axis2/transport/TransportUtils.html" target="_top">Frames</a></li>
<li><a href="TransportUtils.html" target="_top">No Frames</a></li>
</ul>
<ul class="navList" id="allclasses_navbar_top">
<li><a href="../../../../allclasses-noframe.html">All Classes</a></li>
</ul>
<div>
<script type="text/javascript"><!--
allClassesLink = document.getElementById("allclasses_navbar_top");
if(window==top) {
allClassesLink.style.display = "block";
}
else {
allClassesLink.style.display = "none";
}
//-->
</script>
</div>
<div>
<ul class="subNavList">
<li>Summary:&nbsp;</li>
<li>Nested&nbsp;|&nbsp;</li>
<li>Field&nbsp;|&nbsp;</li>
<li><a href="#constructor_summary">Constr</a>&nbsp;|&nbsp;</li>
<li><a href="#method_summary">Method</a></li>
</ul>
<ul class="subNavList">
<li>Detail:&nbsp;</li>
<li>Field&nbsp;|&nbsp;</li>
<li><a href="#constructor_detail">Constr</a>&nbsp;|&nbsp;</li>
<li><a href="#method_detail">Method</a></li>
</ul>
</div>
<a name="skip-navbar_top">
<!-- -->
</a></div>
<!-- ========= END OF TOP NAVBAR ========= -->
<!-- ======== START OF CLASS DATA ======== -->
<div class="header">
<div class="subTitle">org.apache.axis2.transport</div>
<h2 title="Class TransportUtils" class="title">Class TransportUtils</h2>
</div>
<div class="contentContainer">
<ul class="inheritance">
<li><a href="https://docs.oracle.com/javase/7/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">java.lang.Object</a></li>
<li>
<ul class="inheritance">
<li>org.apache.axis2.transport.TransportUtils</li>
</ul>
</li>
</ul>
<div class="description">
<ul class="blockList">
<li class="blockList">
<hr>
<br>
<pre>public class <span class="strong">TransportUtils</span>
extends <a href="https://docs.oracle.com/javase/7/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</a></pre>
</li>
</ul>
</div>
<div class="summary">
<ul class="blockList">
<li class="blockList">
<!-- ======== CONSTRUCTOR SUMMARY ======== -->
<ul class="blockList">
<li class="blockList"><a name="constructor_summary">
<!-- -->
</a>
<h3>Constructor Summary</h3>
<table class="overviewSummary" border="0" cellpadding="3" cellspacing="0" summary="Constructor Summary table, listing constructors, and an explanation">
<caption><span>Constructors</span><span class="tabEnd">&nbsp;</span></caption>
<tr>
<th class="colOne" scope="col">Constructor and Description</th>
</tr>
<tr class="altColor">
<td class="colOne"><code><strong><a href="../../../../org/apache/axis2/transport/TransportUtils.html#TransportUtils()">TransportUtils</a></strong>()</code>&nbsp;</td>
</tr>
</table>
</li>
</ul>
<!-- ========== METHOD SUMMARY =========== -->
<ul class="blockList">
<li class="blockList"><a name="method_summary">
<!-- -->
</a>
<h3>Method Summary</h3>
<table class="overviewSummary" border="0" cellpadding="3" cellspacing="0" summary="Method Summary table, listing methods, and an explanation">
<caption><span>Methods</span><span class="tabEnd">&nbsp;</span></caption>
<tr>
<th class="colFirst" scope="col">Modifier and Type</th>
<th class="colLast" scope="col">Method and Description</th>
</tr>
<tr class="altColor">
<td class="colFirst"><code>static <a href="http://ws.apache.org/axiom/apidocs/org/apache/axiom/om/OMElement.html?is-external=true" title="class or interface in org.apache.axiom.om">OMElement</a></code></td>
<td class="colLast"><code><strong><a href="../../../../org/apache/axis2/transport/TransportUtils.html#createDocumentElement(java.lang.String, org.apache.axis2.builder.Builder, org.apache.axis2.context.MessageContext, java.io.InputStream)">createDocumentElement</a></strong>(<a href="https://docs.oracle.com/javase/7/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a>&nbsp;contentType,
<a href="../../../../org/apache/axis2/builder/Builder.html" title="interface in org.apache.axis2.builder">Builder</a>&nbsp;builder,
<a href="../../../../org/apache/axis2/context/MessageContext.html" title="class in org.apache.axis2.context">MessageContext</a>&nbsp;msgContext,
<a href="https://docs.oracle.com/javase/7/docs/api/java/io/InputStream.html?is-external=true" title="class or interface in java.io">InputStream</a>&nbsp;inStream)</code>&nbsp;</td>
</tr>
<tr class="rowColor">
<td class="colFirst"><code>static <a href="http://ws.apache.org/axiom/apidocs/org/apache/axiom/om/OMElement.html?is-external=true" title="class or interface in org.apache.axiom.om">OMElement</a></code></td>
<td class="colLast"><code><strong><a href="../../../../org/apache/axis2/transport/TransportUtils.html#createDocumentElement(java.lang.String, org.apache.axis2.context.MessageContext, java.io.InputStream)">createDocumentElement</a></strong>(<a href="https://docs.oracle.com/javase/7/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a>&nbsp;contentType,
<a href="../../../../org/apache/axis2/context/MessageContext.html" title="class in org.apache.axis2.context">MessageContext</a>&nbsp;msgContext,
<a href="https://docs.oracle.com/javase/7/docs/api/java/io/InputStream.html?is-external=true" title="class or interface in java.io">InputStream</a>&nbsp;inStream)</code>&nbsp;</td>
</tr>
<tr class="altColor">
<td class="colFirst"><code>static <a href="http://ws.apache.org/axiom/apidocs/org/apache/axiom/soap/SOAPEnvelope.html?is-external=true" title="class or interface in org.apache.axiom.soap">SOAPEnvelope</a></code></td>
<td class="colLast"><code><strong><a href="../../../../org/apache/axis2/transport/TransportUtils.html#createSOAPEnvelope(org.apache.axiom.om.OMElement)">createSOAPEnvelope</a></strong>(<a href="http://ws.apache.org/axiom/apidocs/org/apache/axiom/om/OMElement.html?is-external=true" title="class or interface in org.apache.axiom.om">OMElement</a>&nbsp;documentElement)</code>&nbsp;</td>
</tr>
<tr class="rowColor">
<td class="colFirst"><code>static <a href="http://ws.apache.org/axiom/apidocs/org/apache/axiom/soap/SOAPEnvelope.html?is-external=true" title="class or interface in org.apache.axiom.soap">SOAPEnvelope</a></code></td>
<td class="colLast"><code><strong><a href="../../../../org/apache/axis2/transport/TransportUtils.html#createSOAPMessage(org.apache.axis2.context.MessageContext)">createSOAPMessage</a></strong>(<a href="../../../../org/apache/axis2/context/MessageContext.html" title="class in org.apache.axis2.context">MessageContext</a>&nbsp;msgContext)</code>&nbsp;</td>
</tr>
<tr class="altColor">
<td class="colFirst"><code>static <a href="http://ws.apache.org/axiom/apidocs/org/apache/axiom/soap/SOAPEnvelope.html?is-external=true" title="class or interface in org.apache.axiom.soap">SOAPEnvelope</a></code></td>
<td class="colLast"><code><strong><a href="../../../../org/apache/axis2/transport/TransportUtils.html#createSOAPMessage(org.apache.axis2.context.MessageContext, boolean)">createSOAPMessage</a></strong>(<a href="../../../../org/apache/axis2/context/MessageContext.html" title="class in org.apache.axis2.context">MessageContext</a>&nbsp;msgContext,
boolean&nbsp;detach)</code>
<div class="block">This method will create a SOAPEnvelope based on the InputStream stored on
the MessageContext.</div>
</td>
</tr>
<tr class="rowColor">
<td class="colFirst"><code>static <a href="http://ws.apache.org/axiom/apidocs/org/apache/axiom/soap/SOAPEnvelope.html?is-external=true" title="class or interface in org.apache.axiom.soap">SOAPEnvelope</a></code></td>
<td class="colLast"><code><strong><a href="../../../../org/apache/axis2/transport/TransportUtils.html#createSOAPMessage(org.apache.axis2.context.MessageContext, java.io.InputStream, java.lang.String)">createSOAPMessage</a></strong>(<a href="../../../../org/apache/axis2/context/MessageContext.html" title="class in org.apache.axis2.context">MessageContext</a>&nbsp;msgContext,
<a href="https://docs.oracle.com/javase/7/docs/api/java/io/InputStream.html?is-external=true" title="class or interface in java.io">InputStream</a>&nbsp;inStream,
<a href="https://docs.oracle.com/javase/7/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a>&nbsp;contentType)</code>
<div class="block">Objective of this method is to capture the SOAPEnvelope creation logic
and make it a common for all the transports and to in/out flows.</div>
</td>
</tr>
<tr class="altColor">
<td class="colFirst"><code>static <a href="http://ws.apache.org/axiom/apidocs/org/apache/axiom/soap/SOAPEnvelope.html?is-external=true" title="class or interface in org.apache.axiom.soap">SOAPEnvelope</a></code></td>
<td class="colLast"><code><strong><a href="../../../../org/apache/axis2/transport/TransportUtils.html#createSOAPMessage(org.apache.axis2.context.MessageContext, java.io.InputStream, java.lang.String, org.apache.axis2.builder.Builder)">createSOAPMessage</a></strong>(<a href="../../../../org/apache/axis2/context/MessageContext.html" title="class in org.apache.axis2.context">MessageContext</a>&nbsp;msgContext,
<a href="https://docs.oracle.com/javase/7/docs/api/java/io/InputStream.html?is-external=true" title="class or interface in java.io">InputStream</a>&nbsp;inStream,
<a href="https://docs.oracle.com/javase/7/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a>&nbsp;contentType,
<a href="../../../../org/apache/axis2/builder/Builder.html" title="interface in org.apache.axis2.builder">Builder</a>&nbsp;builder)</code>
<div class="block">Objective of this method is to capture the SOAPEnvelope creation logic
and make it a common for all the transports and to in/out flows.</div>
</td>
</tr>
<tr class="rowColor">
<td class="colFirst"><code>static void</code></td>
<td class="colLast"><code><strong><a href="../../../../org/apache/axis2/transport/TransportUtils.html#deleteAttachments(org.apache.axis2.context.MessageContext)">deleteAttachments</a></strong>(<a href="../../../../org/apache/axis2/context/MessageContext.html" title="class in org.apache.axis2.context">MessageContext</a>&nbsp;msgContext)</code>
<div class="block">Clean up cached attachment file</div>
</td>
</tr>
<tr class="altColor">
<td class="colFirst"><code>static void</code></td>
<td class="colLast"><code><strong><a href="../../../../org/apache/axis2/transport/TransportUtils.html#detachInputStream(org.apache.axis2.context.MessageContext)">detachInputStream</a></strong>(<a href="../../../../org/apache/axis2/context/MessageContext.html" title="class in org.apache.axis2.context">MessageContext</a>&nbsp;msgContext)</code>
<div class="block">This method can be called by components wishing to detach the DetachableInputStream
object that is present on the MessageContext.</div>
</td>
</tr>
<tr class="rowColor">
<td class="colFirst"><code>static boolean</code></td>
<td class="colLast"><code><strong><a href="../../../../org/apache/axis2/transport/TransportUtils.html#doWriteMTOM(org.apache.axis2.context.MessageContext)">doWriteMTOM</a></strong>(<a href="../../../../org/apache/axis2/context/MessageContext.html" title="class in org.apache.axis2.context">MessageContext</a>&nbsp;msgContext)</code>
<div class="block">
Checks whether MTOM needs to be enabled for the message represented by
the msgContext.</div>
</td>
</tr>
<tr class="altColor">
<td class="colFirst"><code>static boolean</code></td>
<td class="colLast"><code><strong><a href="../../../../org/apache/axis2/transport/TransportUtils.html#doWriteSwA(org.apache.axis2.context.MessageContext)">doWriteSwA</a></strong>(<a href="../../../../org/apache/axis2/context/MessageContext.html" title="class in org.apache.axis2.context">MessageContext</a>&nbsp;msgContext)</code>
<div class="block">
Checks whether SOAP With Attachments (SwA) needs to be enabled for the
message represented by the msgContext.</div>
</td>
</tr>
<tr class="rowColor">
<td class="colFirst"><code>static <a href="https://docs.oracle.com/javase/7/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a></code></td>
<td class="colLast"><code><strong><a href="../../../../org/apache/axis2/transport/TransportUtils.html#getCharSetEncoding(org.apache.axis2.context.MessageContext)">getCharSetEncoding</a></strong>(<a href="../../../../org/apache/axis2/context/MessageContext.html" title="class in org.apache.axis2.context">MessageContext</a>&nbsp;msgContext)</code>
<div class="block">Utility method to query CharSetEncoding.</div>
</td>
</tr>
<tr class="altColor">
<td class="colFirst"><code>static <a href="https://docs.oracle.com/javase/7/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a></code></td>
<td class="colLast"><code><strong><a href="../../../../org/apache/axis2/transport/TransportUtils.html#getCharSetEncoding(java.lang.String)">getCharSetEncoding</a></strong>(<a href="https://docs.oracle.com/javase/7/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a>&nbsp;contentType)</code>
<div class="block">Extracts and returns the character set encoding from the
Content-type header
Example:
Content-Type: text/xml; charset=utf-8</div>
</td>
</tr>
<tr class="rowColor">
<td class="colFirst"><code>static <a href="https://docs.oracle.com/javase/7/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a></code></td>
<td class="colLast"><code><strong><a href="../../../../org/apache/axis2/transport/TransportUtils.html#getContentType(java.lang.String, org.apache.axis2.context.MessageContext)">getContentType</a></strong>(<a href="https://docs.oracle.com/javase/7/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a>&nbsp;contentType,
<a href="../../../../org/apache/axis2/context/MessageContext.html" title="class in org.apache.axis2.context">MessageContext</a>&nbsp;msgContext)</code>&nbsp;</td>
</tr>
<tr class="altColor">
<td class="colFirst"><code>static boolean</code></td>
<td class="colLast"><code><strong><a href="../../../../org/apache/axis2/transport/TransportUtils.html#isDoingREST(org.apache.axis2.context.MessageContext)">isDoingREST</a></strong>(<a href="../../../../org/apache/axis2/context/MessageContext.html" title="class in org.apache.axis2.context">MessageContext</a>&nbsp;msgContext)</code>&nbsp;</td>
</tr>
<tr class="rowColor">
<td class="colFirst"><code>static boolean</code></td>
<td class="colLast"><code><strong><a href="../../../../org/apache/axis2/transport/TransportUtils.html#isResponseWritten(org.apache.axis2.context.MessageContext)">isResponseWritten</a></strong>(<a href="../../../../org/apache/axis2/context/MessageContext.html" title="class in org.apache.axis2.context">MessageContext</a>&nbsp;messageContext)</code>
<div class="block">This is a helper method to get the response written flag from the RequestResponseTransport
instance.</div>
</td>
</tr>
<tr class="altColor">
<td class="colFirst"><code>static void</code></td>
<td class="colLast"><code><strong><a href="../../../../org/apache/axis2/transport/TransportUtils.html#processContentTypeForAction(java.lang.String, org.apache.axis2.context.MessageContext)">processContentTypeForAction</a></strong>(<a href="https://docs.oracle.com/javase/7/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a>&nbsp;contentType,
<a href="../../../../org/apache/axis2/context/MessageContext.html" title="class in org.apache.axis2.context">MessageContext</a>&nbsp;msgContext)</code>&nbsp;</td>
</tr>
<tr class="rowColor">
<td class="colFirst"><code>static void</code></td>
<td class="colLast"><code><strong><a href="../../../../org/apache/axis2/transport/TransportUtils.html#setResponseWritten(org.apache.axis2.context.MessageContext, boolean)">setResponseWritten</a></strong>(<a href="../../../../org/apache/axis2/context/MessageContext.html" title="class in org.apache.axis2.context">MessageContext</a>&nbsp;messageContext,
boolean&nbsp;responseWritten)</code>
<div class="block">This is a helper method to set the response written flag on the RequestResponseTransport
instance.</div>
</td>
</tr>
<tr class="altColor">
<td class="colFirst"><code>static void</code></td>
<td class="colLast"><code><strong><a href="../../../../org/apache/axis2/transport/TransportUtils.html#writeMessage(org.apache.axis2.context.MessageContext, java.io.OutputStream)">writeMessage</a></strong>(<a href="../../../../org/apache/axis2/context/MessageContext.html" title="class in org.apache.axis2.context">MessageContext</a>&nbsp;msgContext,
<a href="https://docs.oracle.com/javase/7/docs/api/java/io/OutputStream.html?is-external=true" title="class or interface in java.io">OutputStream</a>&nbsp;out)</code>&nbsp;</td>
</tr>
</table>
<ul class="blockList">
<li class="blockList"><a name="methods_inherited_from_class_java.lang.Object">
<!-- -->
</a>
<h3>Methods inherited from class&nbsp;java.lang.<a href="https://docs.oracle.com/javase/7/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</a></h3>
<code><a href="https://docs.oracle.com/javase/7/docs/api/java/lang/Object.html?is-external=true#clone()" title="class or interface in java.lang">clone</a>, <a href="https://docs.oracle.com/javase/7/docs/api/java/lang/Object.html?is-external=true#equals(java.lang.Object)" title="class or interface in java.lang">equals</a>, <a href="https://docs.oracle.com/javase/7/docs/api/java/lang/Object.html?is-external=true#finalize()" title="class or interface in java.lang">finalize</a>, <a href="https://docs.oracle.com/javase/7/docs/api/java/lang/Object.html?is-external=true#getClass()" title="class or interface in java.lang">getClass</a>, <a href="https://docs.oracle.com/javase/7/docs/api/java/lang/Object.html?is-external=true#hashCode()" title="class or interface in java.lang">hashCode</a>, <a href="https://docs.oracle.com/javase/7/docs/api/java/lang/Object.html?is-external=true#notify()" title="class or interface in java.lang">notify</a>, <a href="https://docs.oracle.com/javase/7/docs/api/java/lang/Object.html?is-external=true#notifyAll()" title="class or interface in java.lang">notifyAll</a>, <a href="https://docs.oracle.com/javase/7/docs/api/java/lang/Object.html?is-external=true#toString()" title="class or interface in java.lang">toString</a>, <a href="https://docs.oracle.com/javase/7/docs/api/java/lang/Object.html?is-external=true#wait()" title="class or interface in java.lang">wait</a>, <a href="https://docs.oracle.com/javase/7/docs/api/java/lang/Object.html?is-external=true#wait(long)" title="class or interface in java.lang">wait</a>, <a href="https://docs.oracle.com/javase/7/docs/api/java/lang/Object.html?is-external=true#wait(long, int)" title="class or interface in java.lang">wait</a></code></li>
</ul>
</li>
</ul>
</li>
</ul>
</div>
<div class="details">
<ul class="blockList">
<li class="blockList">
<!-- ========= CONSTRUCTOR DETAIL ======== -->
<ul class="blockList">
<li class="blockList"><a name="constructor_detail">
<!-- -->
</a>
<h3>Constructor Detail</h3>
<a name="TransportUtils()">
<!-- -->
</a>
<ul class="blockListLast">
<li class="blockList">
<h4>TransportUtils</h4>
<pre>public&nbsp;TransportUtils()</pre>
</li>
</ul>
</li>
</ul>
<!-- ============ METHOD DETAIL ========== -->
<ul class="blockList">
<li class="blockList"><a name="method_detail">
<!-- -->
</a>
<h3>Method Detail</h3>
<a name="createSOAPMessage(org.apache.axis2.context.MessageContext)">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>createSOAPMessage</h4>
<pre>public static&nbsp;<a href="http://ws.apache.org/axiom/apidocs/org/apache/axiom/soap/SOAPEnvelope.html?is-external=true" title="class or interface in org.apache.axiom.soap">SOAPEnvelope</a>&nbsp;createSOAPMessage(<a href="../../../../org/apache/axis2/context/MessageContext.html" title="class in org.apache.axis2.context">MessageContext</a>&nbsp;msgContext)
throws <a href="../../../../org/apache/axis2/AxisFault.html" title="class in org.apache.axis2">AxisFault</a></pre>
<dl><dt><span class="strong">Throws:</span></dt>
<dd><code><a href="../../../../org/apache/axis2/AxisFault.html" title="class in org.apache.axis2">AxisFault</a></code></dd></dl>
</li>
</ul>
<a name="createSOAPMessage(org.apache.axis2.context.MessageContext, boolean)">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>createSOAPMessage</h4>
<pre>public static&nbsp;<a href="http://ws.apache.org/axiom/apidocs/org/apache/axiom/soap/SOAPEnvelope.html?is-external=true" title="class or interface in org.apache.axiom.soap">SOAPEnvelope</a>&nbsp;createSOAPMessage(<a href="../../../../org/apache/axis2/context/MessageContext.html" title="class in org.apache.axis2.context">MessageContext</a>&nbsp;msgContext,
boolean&nbsp;detach)
throws <a href="../../../../org/apache/axis2/AxisFault.html" title="class in org.apache.axis2">AxisFault</a></pre>
<div class="block">This method will create a SOAPEnvelope based on the InputStream stored on
the MessageContext. The 'detach' parameter controls whether or not the
underlying DetachableInputStream is detached at the end of the method. Note,
detaching the DetachableInputStream closes the underlying InputStream that
is stored on the MessageContext.</div>
<dl><dt><span class="strong">Throws:</span></dt>
<dd><code><a href="../../../../org/apache/axis2/AxisFault.html" title="class in org.apache.axis2">AxisFault</a></code></dd></dl>
</li>
</ul>
<a name="createSOAPMessage(org.apache.axis2.context.MessageContext, java.io.InputStream, java.lang.String)">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>createSOAPMessage</h4>
<pre>public static&nbsp;<a href="http://ws.apache.org/axiom/apidocs/org/apache/axiom/soap/SOAPEnvelope.html?is-external=true" title="class or interface in org.apache.axiom.soap">SOAPEnvelope</a>&nbsp;createSOAPMessage(<a href="../../../../org/apache/axis2/context/MessageContext.html" title="class in org.apache.axis2.context">MessageContext</a>&nbsp;msgContext,
<a href="https://docs.oracle.com/javase/7/docs/api/java/io/InputStream.html?is-external=true" title="class or interface in java.io">InputStream</a>&nbsp;inStream,
<a href="https://docs.oracle.com/javase/7/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a>&nbsp;contentType)
throws <a href="../../../../org/apache/axis2/AxisFault.html" title="class in org.apache.axis2">AxisFault</a>,
<a href="http://ws.apache.org/axiom/apidocs/org/apache/axiom/om/OMException.html?is-external=true" title="class or interface in org.apache.axiom.om">OMException</a>,
<a href="https://docs.oracle.com/javase/7/docs/api/javax/xml/stream/XMLStreamException.html?is-external=true" title="class or interface in javax.xml.stream">XMLStreamException</a>,
<a href="https://docs.oracle.com/javase/7/docs/api/javax/xml/parsers/FactoryConfigurationError.html?is-external=true" title="class or interface in javax.xml.parsers">FactoryConfigurationError</a></pre>
<div class="block">Objective of this method is to capture the SOAPEnvelope creation logic
and make it a common for all the transports and to in/out flows.</div>
<dl><dt><span class="strong">Parameters:</span></dt><dd><code>msgContext</code> - message context</dd><dd><code>inStream</code> - input stream</dd><dd><code>contentType</code> - content type of the message</dd>
<dt><span class="strong">Returns:</span></dt><dd>the SOAPEnvelope</dd>
<dt><span class="strong">Throws:</span></dt>
<dd><code><a href="../../../../org/apache/axis2/AxisFault.html" title="class in org.apache.axis2">AxisFault</a></code> - if an error occurs</dd>
<dd><code><a href="http://ws.apache.org/axiom/apidocs/org/apache/axiom/om/OMException.html?is-external=true" title="class or interface in org.apache.axiom.om">OMException</a></code> - if the xml is invalid</dd>
<dd><code><a href="https://docs.oracle.com/javase/7/docs/api/javax/xml/stream/XMLStreamException.html?is-external=true" title="class or interface in javax.xml.stream">XMLStreamException</a></code> - if the stream is invalid</dd>
<dd><code><a href="https://docs.oracle.com/javase/7/docs/api/javax/xml/parsers/FactoryConfigurationError.html?is-external=true" title="class or interface in javax.xml.parsers">FactoryConfigurationError</a></code></dd></dl>
</li>
</ul>
<a name="createSOAPMessage(org.apache.axis2.context.MessageContext, java.io.InputStream, java.lang.String, org.apache.axis2.builder.Builder)">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>createSOAPMessage</h4>
<pre>public static&nbsp;<a href="http://ws.apache.org/axiom/apidocs/org/apache/axiom/soap/SOAPEnvelope.html?is-external=true" title="class or interface in org.apache.axiom.soap">SOAPEnvelope</a>&nbsp;createSOAPMessage(<a href="../../../../org/apache/axis2/context/MessageContext.html" title="class in org.apache.axis2.context">MessageContext</a>&nbsp;msgContext,
<a href="https://docs.oracle.com/javase/7/docs/api/java/io/InputStream.html?is-external=true" title="class or interface in java.io">InputStream</a>&nbsp;inStream,
<a href="https://docs.oracle.com/javase/7/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a>&nbsp;contentType,
<a href="../../../../org/apache/axis2/builder/Builder.html" title="interface in org.apache.axis2.builder">Builder</a>&nbsp;builder)
throws <a href="../../../../org/apache/axis2/AxisFault.html" title="class in org.apache.axis2">AxisFault</a>,
<a href="http://ws.apache.org/axiom/apidocs/org/apache/axiom/om/OMException.html?is-external=true" title="class or interface in org.apache.axiom.om">OMException</a>,
<a href="https://docs.oracle.com/javase/7/docs/api/javax/xml/stream/XMLStreamException.html?is-external=true" title="class or interface in javax.xml.stream">XMLStreamException</a>,
<a href="https://docs.oracle.com/javase/7/docs/api/javax/xml/parsers/FactoryConfigurationError.html?is-external=true" title="class or interface in javax.xml.parsers">FactoryConfigurationError</a></pre>
<div class="block">Objective of this method is to capture the SOAPEnvelope creation logic
and make it a common for all the transports and to in/out flows.</div>
<dl><dt><span class="strong">Parameters:</span></dt><dd><code>msgContext</code> - message context</dd><dd><code>inStream</code> - input stream</dd><dd><code>contentType</code> - content type of the message</dd><dd><code>builder</code> - the builder to be used</dd>
<dt><span class="strong">Returns:</span></dt><dd>the SOAPEnvelope</dd>
<dt><span class="strong">Throws:</span></dt>
<dd><code><a href="../../../../org/apache/axis2/AxisFault.html" title="class in org.apache.axis2">AxisFault</a></code> - if an error occurs</dd>
<dd><code><a href="http://ws.apache.org/axiom/apidocs/org/apache/axiom/om/OMException.html?is-external=true" title="class or interface in org.apache.axiom.om">OMException</a></code> - if the xml is invalid</dd>
<dd><code><a href="https://docs.oracle.com/javase/7/docs/api/javax/xml/stream/XMLStreamException.html?is-external=true" title="class or interface in javax.xml.stream">XMLStreamException</a></code> - if the stream is invalid</dd>
<dd><code><a href="https://docs.oracle.com/javase/7/docs/api/javax/xml/parsers/FactoryConfigurationError.html?is-external=true" title="class or interface in javax.xml.parsers">FactoryConfigurationError</a></code></dd></dl>
</li>
</ul>
<a name="createSOAPEnvelope(org.apache.axiom.om.OMElement)">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>createSOAPEnvelope</h4>
<pre>public static&nbsp;<a href="http://ws.apache.org/axiom/apidocs/org/apache/axiom/soap/SOAPEnvelope.html?is-external=true" title="class or interface in org.apache.axiom.soap">SOAPEnvelope</a>&nbsp;createSOAPEnvelope(<a href="http://ws.apache.org/axiom/apidocs/org/apache/axiom/om/OMElement.html?is-external=true" title="class or interface in org.apache.axiom.om">OMElement</a>&nbsp;documentElement)</pre>
</li>
</ul>
<a name="createDocumentElement(java.lang.String, org.apache.axis2.context.MessageContext, java.io.InputStream)">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>createDocumentElement</h4>
<pre>public static&nbsp;<a href="http://ws.apache.org/axiom/apidocs/org/apache/axiom/om/OMElement.html?is-external=true" title="class or interface in org.apache.axiom.om">OMElement</a>&nbsp;createDocumentElement(<a href="https://docs.oracle.com/javase/7/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a>&nbsp;contentType,
<a href="../../../../org/apache/axis2/context/MessageContext.html" title="class in org.apache.axis2.context">MessageContext</a>&nbsp;msgContext,
<a href="https://docs.oracle.com/javase/7/docs/api/java/io/InputStream.html?is-external=true" title="class or interface in java.io">InputStream</a>&nbsp;inStream)
throws <a href="../../../../org/apache/axis2/AxisFault.html" title="class in org.apache.axis2">AxisFault</a>,
<a href="https://docs.oracle.com/javase/7/docs/api/javax/xml/stream/XMLStreamException.html?is-external=true" title="class or interface in javax.xml.stream">XMLStreamException</a></pre>
<dl><dt><span class="strong">Throws:</span></dt>
<dd><code><a href="../../../../org/apache/axis2/AxisFault.html" title="class in org.apache.axis2">AxisFault</a></code></dd>
<dd><code><a href="https://docs.oracle.com/javase/7/docs/api/javax/xml/stream/XMLStreamException.html?is-external=true" title="class or interface in javax.xml.stream">XMLStreamException</a></code></dd></dl>
</li>
</ul>
<a name="createDocumentElement(java.lang.String, org.apache.axis2.builder.Builder, org.apache.axis2.context.MessageContext, java.io.InputStream)">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>createDocumentElement</h4>
<pre>public static&nbsp;<a href="http://ws.apache.org/axiom/apidocs/org/apache/axiom/om/OMElement.html?is-external=true" title="class or interface in org.apache.axiom.om">OMElement</a>&nbsp;createDocumentElement(<a href="https://docs.oracle.com/javase/7/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a>&nbsp;contentType,
<a href="../../../../org/apache/axis2/builder/Builder.html" title="interface in org.apache.axis2.builder">Builder</a>&nbsp;builder,
<a href="../../../../org/apache/axis2/context/MessageContext.html" title="class in org.apache.axis2.context">MessageContext</a>&nbsp;msgContext,
<a href="https://docs.oracle.com/javase/7/docs/api/java/io/InputStream.html?is-external=true" title="class or interface in java.io">InputStream</a>&nbsp;inStream)
throws <a href="../../../../org/apache/axis2/AxisFault.html" title="class in org.apache.axis2">AxisFault</a>,
<a href="https://docs.oracle.com/javase/7/docs/api/javax/xml/stream/XMLStreamException.html?is-external=true" title="class or interface in javax.xml.stream">XMLStreamException</a></pre>
<dl><dt><span class="strong">Throws:</span></dt>
<dd><code><a href="../../../../org/apache/axis2/AxisFault.html" title="class in org.apache.axis2">AxisFault</a></code></dd>
<dd><code><a href="https://docs.oracle.com/javase/7/docs/api/javax/xml/stream/XMLStreamException.html?is-external=true" title="class or interface in javax.xml.stream">XMLStreamException</a></code></dd></dl>
</li>
</ul>
<a name="getContentType(java.lang.String, org.apache.axis2.context.MessageContext)">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>getContentType</h4>
<pre>public static&nbsp;<a href="https://docs.oracle.com/javase/7/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a>&nbsp;getContentType(<a href="https://docs.oracle.com/javase/7/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a>&nbsp;contentType,
<a href="../../../../org/apache/axis2/context/MessageContext.html" title="class in org.apache.axis2.context">MessageContext</a>&nbsp;msgContext)</pre>
</li>
</ul>
<a name="getCharSetEncoding(java.lang.String)">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>getCharSetEncoding</h4>
<pre>public static&nbsp;<a href="https://docs.oracle.com/javase/7/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a>&nbsp;getCharSetEncoding(<a href="https://docs.oracle.com/javase/7/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a>&nbsp;contentType)</pre>
<div class="block">Extracts and returns the character set encoding from the
Content-type header
Example:
Content-Type: text/xml; charset=utf-8</div>
<dl><dt><span class="strong">Parameters:</span></dt><dd><code>contentType</code> - </dd></dl>
</li>
</ul>
<a name="writeMessage(org.apache.axis2.context.MessageContext, java.io.OutputStream)">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>writeMessage</h4>
<pre>public static&nbsp;void&nbsp;writeMessage(<a href="../../../../org/apache/axis2/context/MessageContext.html" title="class in org.apache.axis2.context">MessageContext</a>&nbsp;msgContext,
<a href="https://docs.oracle.com/javase/7/docs/api/java/io/OutputStream.html?is-external=true" title="class or interface in java.io">OutputStream</a>&nbsp;out)
throws <a href="../../../../org/apache/axis2/AxisFault.html" title="class in org.apache.axis2">AxisFault</a></pre>
<dl><dt><span class="strong">Throws:</span></dt>
<dd><code><a href="../../../../org/apache/axis2/AxisFault.html" title="class in org.apache.axis2">AxisFault</a></code></dd></dl>
</li>
</ul>
<a name="processContentTypeForAction(java.lang.String, org.apache.axis2.context.MessageContext)">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>processContentTypeForAction</h4>
<pre>public static&nbsp;void&nbsp;processContentTypeForAction(<a href="https://docs.oracle.com/javase/7/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a>&nbsp;contentType,
<a href="../../../../org/apache/axis2/context/MessageContext.html" title="class in org.apache.axis2.context">MessageContext</a>&nbsp;msgContext)</pre>
</li>
</ul>
<a name="isResponseWritten(org.apache.axis2.context.MessageContext)">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>isResponseWritten</h4>
<pre>public static&nbsp;boolean&nbsp;isResponseWritten(<a href="../../../../org/apache/axis2/context/MessageContext.html" title="class in org.apache.axis2.context">MessageContext</a>&nbsp;messageContext)</pre>
<div class="block">This is a helper method to get the response written flag from the RequestResponseTransport
instance.</div>
</li>
</ul>
<a name="setResponseWritten(org.apache.axis2.context.MessageContext, boolean)">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>setResponseWritten</h4>
<pre>public static&nbsp;void&nbsp;setResponseWritten(<a href="../../../../org/apache/axis2/context/MessageContext.html" title="class in org.apache.axis2.context">MessageContext</a>&nbsp;messageContext,
boolean&nbsp;responseWritten)</pre>
<div class="block">This is a helper method to set the response written flag on the RequestResponseTransport
instance.</div>
</li>
</ul>
<a name="deleteAttachments(org.apache.axis2.context.MessageContext)">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>deleteAttachments</h4>
<pre>public static&nbsp;void&nbsp;deleteAttachments(<a href="../../../../org/apache/axis2/context/MessageContext.html" title="class in org.apache.axis2.context">MessageContext</a>&nbsp;msgContext)</pre>
<div class="block">Clean up cached attachment file</div>
<dl><dt><span class="strong">Parameters:</span></dt><dd><code>msgContext</code> - </dd></dl>
</li>
</ul>
<a name="detachInputStream(org.apache.axis2.context.MessageContext)">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>detachInputStream</h4>
<pre>public static&nbsp;void&nbsp;detachInputStream(<a href="../../../../org/apache/axis2/context/MessageContext.html" title="class in org.apache.axis2.context">MessageContext</a>&nbsp;msgContext)
throws <a href="../../../../org/apache/axis2/AxisFault.html" title="class in org.apache.axis2">AxisFault</a></pre>
<div class="block">This method can be called by components wishing to detach the DetachableInputStream
object that is present on the MessageContext. This is meant to shield components
from any logic that needs to be executed on the DetachableInputStream in order to
have it effectively detached. If the DetachableInputStream is not present, or if
the supplied MessageContext is null, no action will be taken.</div>
<dl><dt><span class="strong">Throws:</span></dt>
<dd><code><a href="../../../../org/apache/axis2/AxisFault.html" title="class in org.apache.axis2">AxisFault</a></code></dd></dl>
</li>
</ul>
<a name="doWriteMTOM(org.apache.axis2.context.MessageContext)">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>doWriteMTOM</h4>
<pre>public static&nbsp;boolean&nbsp;doWriteMTOM(<a href="../../../../org/apache/axis2/context/MessageContext.html" title="class in org.apache.axis2.context">MessageContext</a>&nbsp;msgContext)</pre>
<div class="block"><p>
Checks whether MTOM needs to be enabled for the message represented by
the msgContext. We check value assigned to the "enableMTOM" property
either using the config files (axis2.xml, services.xml) or
programatically. Programatic configuration is given priority. If the
given value is "optional", MTOM will be enabled only if the incoming
message was an MTOM message.
</p></div>
<dl><dt><span class="strong">Parameters:</span></dt><dd><code>msgContext</code> - the active MessageContext</dd>
<dt><span class="strong">Returns:</span></dt><dd>true if SwA needs to be enabled</dd></dl>
</li>
</ul>
<a name="doWriteSwA(org.apache.axis2.context.MessageContext)">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>doWriteSwA</h4>
<pre>public static&nbsp;boolean&nbsp;doWriteSwA(<a href="../../../../org/apache/axis2/context/MessageContext.html" title="class in org.apache.axis2.context">MessageContext</a>&nbsp;msgContext)</pre>
<div class="block"><p>
Checks whether SOAP With Attachments (SwA) needs to be enabled for the
message represented by the msgContext. We check value assigned to the
"enableSwA" property either using the config files (axis2.xml,
services.xml) or programatically. Programatic configuration is given
priority. If the given value is "optional", SwA will be enabled only if
the incoming message was SwA type.
</p></div>
<dl><dt><span class="strong">Parameters:</span></dt><dd><code>msgContext</code> - the active MessageContext</dd>
<dt><span class="strong">Returns:</span></dt><dd>true if SwA needs to be enabled</dd></dl>
</li>
</ul>
<a name="isDoingREST(org.apache.axis2.context.MessageContext)">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>isDoingREST</h4>
<pre>public static&nbsp;boolean&nbsp;isDoingREST(<a href="../../../../org/apache/axis2/context/MessageContext.html" title="class in org.apache.axis2.context">MessageContext</a>&nbsp;msgContext)</pre>
</li>
</ul>
<a name="getCharSetEncoding(org.apache.axis2.context.MessageContext)">
<!-- -->
</a>
<ul class="blockListLast">
<li class="blockList">
<h4>getCharSetEncoding</h4>
<pre>public static&nbsp;<a href="https://docs.oracle.com/javase/7/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a>&nbsp;getCharSetEncoding(<a href="../../../../org/apache/axis2/context/MessageContext.html" title="class in org.apache.axis2.context">MessageContext</a>&nbsp;msgContext)</pre>
<div class="block">Utility method to query CharSetEncoding. First look in the
MessageContext. If it's not there look in the OpContext. Use the defualt,
if it's not given in either contexts.</div>
<dl><dt><span class="strong">Parameters:</span></dt><dd><code>msgContext</code> - the active MessageContext</dd>
<dt><span class="strong">Returns:</span></dt><dd>String the CharSetEncoding</dd></dl>
</li>
</ul>
</li>
</ul>
</li>
</ul>
</div>
</div>
<!-- ========= END OF CLASS DATA ========= -->
<!-- ======= START OF BOTTOM NAVBAR ====== -->
<div class="bottomNav"><a name="navbar_bottom">
<!-- -->
</a><a href="#skip-navbar_bottom" title="Skip navigation links"></a><a name="navbar_bottom_firstrow">
<!-- -->
</a>
<ul class="navList" title="Navigation">
<li><a href="../../../../overview-summary.html">Overview</a></li>
<li><a href="package-summary.html">Package</a></li>
<li class="navBarCell1Rev">Class</li>
<li><a href="class-use/TransportUtils.html">Use</a></li>
<li><a href="package-tree.html">Tree</a></li>
<li><a href="../../../../deprecated-list.html">Deprecated</a></li>
<li><a href="../../../../index-all.html">Index</a></li>
<li><a href="../../../../help-doc.html">Help</a></li>
</ul>
</div>
<div class="subNav">
<ul class="navList">
<li><a href="../../../../org/apache/axis2/transport/TransportSender.html" title="interface in org.apache.axis2.transport"><span class="strong">Prev Class</span></a></li>
<li><a href="../../../../org/apache/axis2/transport/UtilsTransportServer.html" title="class in org.apache.axis2.transport"><span class="strong">Next Class</span></a></li>
</ul>
<ul class="navList">
<li><a href="../../../../index.html?org/apache/axis2/transport/TransportUtils.html" target="_top">Frames</a></li>
<li><a href="TransportUtils.html" target="_top">No Frames</a></li>
</ul>
<ul class="navList" id="allclasses_navbar_bottom">
<li><a href="../../../../allclasses-noframe.html">All Classes</a></li>
</ul>
<div>
<script type="text/javascript"><!--
allClassesLink = document.getElementById("allclasses_navbar_bottom");
if(window==top) {
allClassesLink.style.display = "block";
}
else {
allClassesLink.style.display = "none";
}
//-->
</script>
</div>
<div>
<ul class="subNavList">
<li>Summary:&nbsp;</li>
<li>Nested&nbsp;|&nbsp;</li>
<li>Field&nbsp;|&nbsp;</li>
<li><a href="#constructor_summary">Constr</a>&nbsp;|&nbsp;</li>
<li><a href="#method_summary">Method</a></li>
</ul>
<ul class="subNavList">
<li>Detail:&nbsp;</li>
<li>Field&nbsp;|&nbsp;</li>
<li><a href="#constructor_detail">Constr</a>&nbsp;|&nbsp;</li>
<li><a href="#method_detail">Method</a></li>
</ul>
</div>
<a name="skip-navbar_bottom">
<!-- -->
</a></div>
<!-- ======== END OF BOTTOM NAVBAR ======= -->
<p class="legalCopy"><small>Copyright &copy; <a href="https://www.apache.org/">The Apache Software Foundation</a>. All Rights Reserved.</small></p>
</body>
</html>