final Element next = nodes.iterator().next();
return next.getText();
}
private Document getRequestDocument(Action action, ResourceURI resourceURI, OptionSet optionSet, Element bodyContent) {
SoapMessageBuilder message = Soapy.newMessage();
SoapMessageBuilder.EnvelopeBuilder envelope = message.envelope();
try {
addHeaders(envelope, action, resourceURI, optionSet);
} catch (URISyntaxException e) {
throw new IllegalArgumentException(e);
}
BodyBuilder body = envelope.body();
if (bodyContent != null)
body.setContent(bodyContent);
return message.getDocument();
}