Example usage for javax.servlet.jsp.el ELParseException toString

List of usage examples for javax.servlet.jsp.el ELParseException toString

Introduction

In this page you can find the example usage for javax.servlet.jsp.el ELParseException toString.

Prototype

public String toString() 

Source Link

Document

Returns a short description of this throwable.

Usage

From source file:org.apache.jasper.compiler.JspUtil.java

/**
 * Validates the syntax of all ${} expressions within the given string.
 * @param where the approximate location of the expressions in the JSP page
 * @param expressions a string containing zero or more "${}" expressions
 * @param err an error dispatcher to use
 *//*from   ww  w  .j  a  va  2s  .  c om*/
public static void validateExpressions(Mark where, String expressions, Class expectedType,
        FunctionMapper functionMapper, ErrorDispatcher err) throws JasperException {

    try {
        JspUtil.expressionEvaluator.parseExpression(expressions, expectedType, null);
    } catch (ELParseException e) {
        err.jspError(where, "jsp.error.invalid.expression", expressions, e.toString());
    } catch (ELException e) {
        err.jspError(where, "jsp.error.invalid.expression", expressions, e.toString());
    }
}