Guest User

Untitled

a guest
Feb 22nd, 2018
72
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.66 KB | None | 0 0
  1. def result = resp.Body.elementName
  2.  
  3. <?xml version="1.0" encoding="UTF-8"?>
  4. <soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/">
  5. <soapenv:Body>
  6. <ns2:**Response** xmlns:ns2="URL" xmlns="URL" xmlns:ns4="URL" xmlns:ns3="URL" xmlns:ns5="URL">
  7. <something>Code</something>
  8. <somethingDescription>Message</somethingDescription>
  9. <ns2:pending/>
  10. <ns2:posted/>
  11. </ns2:Response>
  12. </soapenv:Body>
  13.  
  14. def xmlContent = ctx.getPreviousResult().getResponseDataAsString();
  15. def resp = new XmlSlurper().parseText(xmlContent);
  16.  
  17. def result = resp.Body.Response;
  18. def respCode = result.reasonCode;
Add Comment
Please, Sign In to add comment