Hi Sandamal,

You can use org.apache.synapse.util.PayloadHelper class for all such
utility methods. Following is an example for your case.

PayloadHelper.setXMLPayload(envelope2,
envelope1.getBody().getFirstElement().cloneOMElement());

Hope this helps. Thanks,


On Tue, Aug 5, 2014 at 12:08 PM, Sandamal Weerasinghe <[email protected]>
wrote:

> Hi,
>
> I need to copy the SOAPBody of one SOAP Envelope and replace the SOAPBody
> of another using it. Does anyone know a fast mechanism to achieve this?
>
> Thanks.
>
> Sandamal Weerasinghe | Software Engineer | WSO2 Lanka (Pvt) Ltd
>
> _______________________________________________
> Dev mailing list
> [email protected]
> http://wso2.org/cgi-bin/mailman/listinfo/dev
>
>


-- 
*Gayan Kaushalya Yalpathwala*
 Software Engineer
WSO2 Inc.; http://wso2.com
lean.enterprise.middleware

mobile: +94 71 8682704 <http://asia14.wso2con.com/>

<http://asia14.wso2con.com/>
_______________________________________________
Dev mailing list
[email protected]
http://wso2.org/cgi-bin/mailman/listinfo/dev

Reply via email to