use of org.mule.runtime.extension.api.soap.SoapAttachment in project mule by mulesoft.
the class SoapOperationExecutor method toSoapAttachments.
private Map<String, SoapAttachment> toSoapAttachments(Map<String, TypedValue<?>> attachments) throws MessageTransformerException, TransformerException {
Map<String, SoapAttachment> soapAttachmentMap = new HashMap<>();
for (Map.Entry<String, TypedValue<?>> attachment : attachments.entrySet()) {
SoapAttachment soapAttachment = new SoapAttachment(toInputStream(attachment.getValue()), attachment.getValue().getDataType().getMediaType());
soapAttachmentMap.put(attachment.getKey(), soapAttachment);
}
return soapAttachmentMap;
}
Aggregations