Evaluates the given EL expression and returns the result as the requested type. The expression is automatically wrapped in {@literal ${}} delimiters before evaluation. @param the expected result type @param expression the EL expression to evaluate @return the result of evaluating the ex
(String expression)
| 77 | * @throws ELException if the expression cannot be evaluated |
| 78 | */ |
| 79 | public <T> T eval(String expression) { |
| 80 | @SuppressWarnings("unchecked") |
| 81 | T result = (T) getValue(expression, Object.class); |
| 82 | return result; |
| 83 | } |
| 84 | |
| 85 | /** |
| 86 | * Evaluates the given EL expression and returns the result coerced to the expected type. |