XmlObject[] childElems = XmlBeanUtils.getChildElements( body.getXmlObject( ) );
Method serviceMethod = null;
if ( childElems.length > 1 )
{
throw new FaultException( Soap1_1Constants.FAULT_CLIENT,
"SOAP request Body contains more than one body element - this service requires that all SOAP requests contain at most one body element." );
}
XmlObject requestXBean;
if ( childElems.length == 0 ) // empty Body
{
requestXBean = null;
if ( methodNameFromAction != null )
{
// try to find a method based on the wsa:Action...
serviceMethod = getServiceMethod( service, methodNameFromAction );
}
else // empty Body and unmapped wsa:Action
{
throw new FaultException( Soap1_1Constants.FAULT_CLIENT,
"No SOAP Body elements were defined, and the value of the WS-Addressing Action header was not recognized - unable to dispatch request." );
}
}
else // childElems.length == 1
{