Search in sources :

Example 6 with MethodInfo

use of jakarta.el.MethodInfo in project tomcat by apache.

the class JspMethodExpression method getMethodInfo.

@Override
public MethodInfo getMethodInfo(ELContext context) throws NullPointerException, PropertyNotFoundException, MethodNotFoundException, ELException {
    context.notifyBeforeEvaluation(getExpressionString());
    try {
        MethodInfo result = this.target.getMethodInfo(context);
        context.notifyAfterEvaluation(getExpressionString());
        return result;
    } catch (MethodNotFoundException e) {
        if (e instanceof JspMethodNotFoundException) {
            throw e;
        }
        throw new JspMethodNotFoundException(this.mark, e);
    } catch (PropertyNotFoundException e) {
        if (e instanceof JspPropertyNotFoundException) {
            throw e;
        }
        throw new JspPropertyNotFoundException(this.mark, e);
    } catch (ELException e) {
        if (e instanceof JspELException) {
            throw e;
        }
        throw new JspELException(this.mark, e);
    }
}
Also used : PropertyNotFoundException(jakarta.el.PropertyNotFoundException) MethodInfo(jakarta.el.MethodInfo) ELException(jakarta.el.ELException) MethodNotFoundException(jakarta.el.MethodNotFoundException)

Aggregations

MethodInfo (jakarta.el.MethodInfo)6 MethodExpression (jakarta.el.MethodExpression)2 Test (org.junit.Test)2 ELException (jakarta.el.ELException)1 MethodNotFoundException (jakarta.el.MethodNotFoundException)1 PropertyNotFoundException (jakarta.el.PropertyNotFoundException)1 Method (java.lang.reflect.Method)1 EvaluationContext (org.apache.el.lang.EvaluationContext)1 Node (org.apache.el.parser.Node)1