respEncStyle = Constants.NS_URI_SOAP_ENC;
}
// invoke the method (directly for Java and via InvokeBSF for script
// methods)
Bean result = null;
try {
if (providerType == DeploymentDescriptor.PROVIDER_JAVA ||
providerType == DeploymentDescriptor.PROVIDER_USER_DEFINED) {
Method m = null ;
try {
m = MethodUtils.getMethod (targetObject,
call.getMethodName(),
argTypes);
} catch (NoSuchMethodException e) {
try {
int paramsCount = 0 ;
if ( params != null ) paramsCount = params.size();
Class[] tmpArgTypes = new Class[paramsCount+1];
Object[] tmpArgs = new Object[paramsCount+1];
for ( int i = 0 ; i < paramsCount ; i++ )
tmpArgTypes[i+1] = argTypes[i] ;
argTypes = tmpArgTypes ;
argTypes[0] = SOAPContext.class ;
m = MethodUtils.getMethod (targetObject,call.getMethodName(),
argTypes);
for ( int i = 0 ; i < paramsCount ; i++ )
tmpArgs[i+1] = args[i] ;
tmpArgs[0] = reqCtx ;
args = tmpArgs ;
} catch (NoSuchMethodException e2) {
/*
Don't want the "No Signature Match" error message to include
the SOAPContext argument.
*/
throw e;
} catch (Exception e2) {
throw e2;
}
} catch (Exception e) {
throw e;
}
result = new Bean (m.getReturnType (), m.invoke (targetObject, args));
} else {
// find the class that provides the BSF services (done
// this way via reflection to avoid a compile-time dependency on BSF)
Class bc = Class.forName ("org.apache.soap.server.InvokeBSF");