开发者

GPathResult to org.w3c.dom.Node

This might be a very simple, but I'll ask anyway.

I have the following code that does a post to a web service. I am using HttpBuilder to build the request and post the payload. The method returns a GPathResult that I need to change into a org.w3c.dom.Node

I am using the Node for xpath evaluation, and need the result to be a org.w3c.dom.Node.

def开发者_高级运维 responseXml
def onResponseHandler = { resp, content ->
            def soapResponse = content instanceof java.io.InputStreamReader ? content.getText() : content
            responseXml = soapResponse.Body
        }

http.post(body: payload, headers: ['Content-Type:': 'text/xml'], onResponseHandler)

return responseXml

I've searched quite extensively for this, but couldn't figure it out. Any ideas?

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜