private Object invokeMethod(Method m, Object base, Object[] params) { Class[] parameterTypes = m.getParameterTypes(); Object[] parameters = null; if (parameterTypes.length > 0) { ExpressionFactory exprFactory = getExpressionFactory(); if (m.isVarArgs()) { // TODO } else { parameters = new Object[parameterTypes.length]; for (int i = 0; i < parameterTypes.length; i++) { parameters[i] = exprFactory.coerceToType(params[i], parameterTypes[i]); } } } try { return m.invoke(base, parameters); } catch (IllegalAccessException iae) { throw new ELException(iae); } catch (InvocationTargetException ite) { throw new ELException(ite.getCause()); } } }
result = target.invoke(base, coerceParams(getExpressionFactory(context), target, params)); } catch (InvocationTargetException e) { throw new ELException(e.getCause());
result = target.invoke(base, coerceParams(getExpressionFactory(context), target, params)); } catch (InvocationTargetException e) { throw new ELException(e.getCause());
result = target.invoke(base, coerceParams(getExpressionFactory(context), target, params)); } catch (InvocationTargetException e) { throw new ELException(e.getCause());