protected MessageFactoryImpl getMessageFactory() { return new MessageFactoryImpl(); } }
/** * Internalizes the contents of the given InputStream object into a new * SOAPMessage object and returns the SOAPMessage object. * * @param mimeHeaders * the transport-specific headers passed to the message in a * transport-independent fashion for creation of the message * @param ins * the InputStream object that contains the data for a message * @return a new SOAPMessage object containing the data from the given * InputStream object * @throws java.io.IOException * if there is a problem in reading data from the input stream * @throws javax.xml.soap.SOAPException * if the message is invalid */ public SOAPMessage createMessage(MimeHeaders mimeHeaders, InputStream ins) throws IOException, SOAPException { return createMessage(mimeHeaders, ins, false); }
ContentType contentType = getContentType(mimeHeaders); if (log.isDebugEnabled()) { log.debug("createMessage: [contentType=" + contentType + "]"); if (isMultipartRelatedContent(contentType)) attachments = decoder.getRelatedParts(); else if (isSoapContent(contentType) == false) envBuilder.setStyle(getStyle()); envBuilder.build(soapMessage, inputStream, ignoreParseError);
MessageFactoryImpl messageFactory = new MessageFactoryImpl(); messageFactory.setStyle(sepMetaData.getStyle()); ep.addAttachment(MessageFactoryImpl.class, messageFactory);
private static MessageFactory newMessageFactory(final String protocol) { try { return new MessageFactoryImpl(protocol); } catch (final SOAPException ignore) { return null; } // TODO: use standard SOAP API to create objects //return MessageFactory.newInstance() }
public Object read(InputStream inputStream, Map<String, Object> metadata, Map<String, Object> headers) throws IOException { if (log.isTraceEnabled()) log.trace("Read input stream with metadata=" + metadata); try { SOAPMessage soapMsg = getMessageFactory().createMessage(null, inputStream, false); return soapMsg; } catch (SOAPException e) { log.error(BundleUtils.getMessage(bundle, "CANNOT_UNMARSHALL_SOAPMESSAGE"), e); IOException e2 = new IOException(e.toString()); e2.initCause(e); throw e2; } }
@Override protected MessageFactory newMessageFactory(String protocol) throws SOAPException { return new MessageFactoryImpl(protocol); }
soapMsg = getMessageFactory().createMessage(mimeHeaders, inputStream, false);
protected MessageFactoryImpl getMessageFactory() { return new MessageFactoryImpl(); }
reqMessage = msgFactory.createMessage(headers, inputStream);