Package org.apache.axis2.transport.http

Examples of org.apache.axis2.transport.http.SOAPMessageFormatter.writeTo()


                    out.flush();
                } catch (IOException e) {
                    throw new AxisFault("Could not compress response");
                }
            } else {
                messageFormatter.writeTo(msgContext, format, out, false);
            }
        } catch (AxisFault axisFault) {
            log.error(axisFault.getMessage(), axisFault);
            throw axisFault;
        }
View Full Code Here


                    return null;
                }
            }
           
            try {
                messageFormatter.writeTo(msgContext, format, out, true);
                out.close();
            } catch (IOException e) {
                handleException("IO Error while creating BytesMessage", e);
            }
View Full Code Here

                    out.flush();
                } catch (IOException e) {
                    throw new AxisFault("Could not compress response");
                }
            } else {
                messageFormatter.writeTo(msgContext, format, out, false);
            }
        } catch (AxisFault axisFault) {
            log.error(axisFault.getMessage(), axisFault);
            throw axisFault;
        }
View Full Code Here

                    return null;
                }
            }
           
            try {
                messageFormatter.writeTo(msgContext, format, out, true);
                out.close();
            } catch (IOException e) {
                handleException("IO Error while creating BytesMessage", e);
            }
View Full Code Here

        try {
            if (msgContext.isPropertyTrue(NhttpConstants.SC_ACCEPTED)) {
                // see comment above on the reasoning
                out.write(new byte[0]);
            } else {
                messageFormatter.writeTo(msgContext, format, out, false);
            }
            out.close();
        } catch (IOException e) {
            handleException("IO Error sending response message", e);
        }
View Full Code Here

                throw new AxisFault(Constants.OUT_TRANSPORT_INFO + " has not been set");
            }
        }

        try {
            messageFormatter.writeTo(msgContext, format, out, false);
            out.close();
        } catch (IOException e) {
            handleException("IO Error sending response message", e);
        }
    }
View Full Code Here

        MessageFormatter messageFormatter = BaseUtils.getMessageFormatter(msgContext);
        OMOutputFormat format = BaseUtils.getOMOutputFormat(msgContext);
        try {
            CountingOutputStream os = new CountingOutputStream(responseFile.getContent().getOutputStream(append));
            try {
                messageFormatter.writeTo(msgContext, format, os, true);
            } finally {
                os.close();
            }
            // update metrics
            metrics.incrementMessagesSent();
View Full Code Here

            String contentType = messageFormatter.getContentType(
                msgContext, format, msgContext.getSoapAction());

            ByteArrayOutputStream baos = new ByteArrayOutputStream();
            try {
                messageFormatter.writeTo(msgContext, format, baos, true);
                baos.flush();
            } catch (IOException e) {
                handleException("IO Error while creating BytesMessage", e);
            }
View Full Code Here

        String contentType = messageFormatter.getContentType(
            msgContext, format, msgContext.getSoapAction());

        ByteArrayOutputStream baos = new ByteArrayOutputStream();
        try {
            messageFormatter.writeTo(msgContext, format, baos, true);
            baos.flush();
            return baos.toByteArray();
        } catch (IOException e) {
            throw new AMQPSynapseException("IO Error while creating message", e);
        }
View Full Code Here

                out.flush();
            } catch (IOException e) {
                throw new AxisFault("Could not compress response");
            }
        } else {
            messageFormatter.writeTo(msgContext, format, out, false);
        }
    }

    private void writeMessageWithCommons(MessageContext messageContext,
                                         EndpointReference toEPR, OMOutputFormat format)
View Full Code Here

TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.