Refactor response generation and xmls
This commit is contained in:
parent
ba63d36fa0
commit
0bfa0d91b4
8 changed files with 50 additions and 36 deletions
|
@ -13,6 +13,7 @@ import org.apache.http.util.EntityUtils
|
|||
class Util {
|
||||
static GPathResult extractXmlResponse(CloseableHttpResponse response) {
|
||||
HttpEntity entity = response.entity
|
||||
|
||||
GPathResult xml = new XmlSlurper().parseText(EntityUtils.toString(entity))
|
||||
EntityUtils.consumeQuietly(entity)
|
||||
return xml
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue