MCPcopy Create free account
hub / github.com/apache/tomcat / eval

Method eval

java/jakarta/el/ELProcessor.java:79–83  ·  view source on GitHub ↗

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)

Source from the content-addressed store, hash-verified

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.

Callers 15

doTestVarArgsBeanFMethod · 0.95
doTestVarArgsBeanGMethod · 0.95
doTestVarArgsBeanHMethod · 0.95
testPreferNoVarArgsMethod · 0.95
testAdd02Method · 0.95
testSubtract02Method · 0.95
testMultiply02Method · 0.95
testDivide02Method · 0.95
testMod02Method · 0.95
testMod03Method · 0.95
testUnaryMinus01Method · 0.95

Calls 1

getValueMethod · 0.95

Tested by 15

doTestVarArgsBeanFMethod · 0.76
doTestVarArgsBeanGMethod · 0.76
doTestVarArgsBeanHMethod · 0.76
testPreferNoVarArgsMethod · 0.76
testAdd02Method · 0.76
testSubtract02Method · 0.76
testMultiply02Method · 0.76
testDivide02Method · 0.76
testMod02Method · 0.76
testMod03Method · 0.76
testUnaryMinus01Method · 0.76