/** * 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); }
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; } }
soapMsg = getMessageFactory().createMessage(mimeHeaders, inputStream, false);
reqMessage = msgFactory.createMessage(headers, inputStream);