public final class MtomRequestEnricher extends AttachmentRequestEnricher
AttachmentRequestEnricher implementation for clients that works with MTOM.definition, loader| Constructor and Description |
|---|
MtomRequestEnricher(WsdlDefinition definition,
org.mule.metadata.api.TypeLoader loader) |
| Modifier and Type | Method and Description |
|---|---|
protected void |
addAttachmentElement(Document bodyDocument,
String name,
org.mule.runtime.extension.api.soap.SoapAttachment attachment,
Element attachmentNode)
Adds the content to the attachment node recently created to the XML SOAP request
|
enrichRequestpublic MtomRequestEnricher(WsdlDefinition definition, org.mule.metadata.api.TypeLoader loader)
protected void addAttachmentElement(Document bodyDocument, String name, org.mule.runtime.extension.api.soap.SoapAttachment attachment, Element attachmentNode)
Adds the XOP element to the attachment node this way the attachments gets tracked with its CID (content id) when it's sent in the multipart request.
Basically adds this content to the attachment node
<xop:Include xmlns:xop="http://www.w3.org/2004/08/xop/include" href="cid:attachmentContentId"/> and uses the
attachmentContentId to identify the attachment in the multipart.
bodyDocument - the document where we are adding the node element.attachment - the attachment to be sent.attachmentNode - the recently created attachment node in the xml request.Copyright © 2003–2017 MuleSoft, Inc.. All rights reserved.