OMOutputFormat format = BaseUtils.getOMOutputFormat(msgContext);
MessageFormatter messageFormatter = null;
try {
messageFormatter = TransportUtils.getMessageFormatter(msgContext);
} catch (AxisFault axisFault) {
throw new BaseTransportException("Unable to get the message formatter to use");
}
try {
OutputStream os = responseFile.getContent().getOutputStream();
messageFormatter.writeTo(msgContext, format, os, true);