}
public SOAPBodyElement buildBodyElementDefault(SOAPBodyImpl soapBody, Element domBodyElement) throws SOAPException
{
QName beName = DOMUtils.getElementQName(domBodyElement);
SOAPBodyElement soapBodyElement = new SOAPBodyElementMessage(beName);
soapBodyElement = (SOAPBodyElementMessage)soapBody.addChildElement(soapBodyElement);
DOMUtils.copyAttributes(soapBodyElement, domBodyElement);
NodeList nlist = domBodyElement.getChildNodes();
for (int i = 0; i < nlist.getLength(); i++)
{
Node child = nlist.item(i);
short childType = child.getNodeType();
if (childType == Node.ELEMENT_NODE)
{
SOAPElement soapElement = soapFactory.createElement((Element)child);
soapBodyElement.addChildElement(soapElement);
}
else if (childType == Node.COMMENT_NODE)
{
appendCommentNode(soapBodyElement, child);
}
else if (childType == Node.TEXT_NODE)
{
appendTextNode(soapBodyElement, child);
}
else if (childType == Node.CDATA_SECTION_NODE)
{
String nodeValue = child.getNodeValue();
soapBodyElement.addTextNode(nodeValue);
}
else
{
log.warn("Ignore child type: " + childType);
}