{
resolverClass=resolver.getResolverClass(objectSource);
}
catch(Exception e)
{
throw new ExecuteException(e);
}
if(resolverClass==null && resolverObject!=null)
resolverClass=resolverObject.getClass();
if(resolverClass == null)
throw new ExecuteException("got null resolver class from Resolver "+SbmUtils.toString(resolver));
methodInfo=findMethodInfo(resolverClass, this.methodName, this.args, true);
if(methodInfo == null)
methodInfo=findMethodInfo(resolverClass, this.methodName, this.args, false);
if(methodInfo == null)
throw new ExecuteException("no method named "+SbmUtils.toString(this.methodName)+" with "+SbmUtils.toString(this.args)
+" arguments can be found in resolver class "+SbmUtils.toString(resolverClass));
setMethodInfo(methodInfo);
}
Object[] argValues=prepareMethodArgValues(methodInfo, objectSource);
try
{
return methodInfo.getMethod().invoke(resolverObject, argValues);
}
catch(InvocationTargetException e)
{
throw new InvocationExecuteException(this, e.getCause());
}
catch(IllegalArgumentException e)
{
throw new ExecuteException(e);
}
catch(IllegalAccessException e)
{
throw new ExecuteException(e);
}
}