/** * Parse the expression passed to the current scanner. If this * expression contains references to local variables and it will be * compiled in an external module (not in the main class) request * the current template to create a new variable stack frame. * * @param lineNumber Line where the current expression is defined. * @param external Set to <tt>true</tt> if this expression is * compiled in a separate module. * */ public Symbol parse(String expression, int lineNumber) throws Exception { try { _expression = expression; _lineNumber = lineNumber; return super.parse(); } catch (IllegalCharException e) { ErrorMsg err = new ErrorMsg(ErrorMsg.ILLEGAL_CHAR_ERR, lineNumber, e.getMessage()); _parser.reportError(Constants.FATAL, err); } return null; }
/** * Parse the expression passed to the current scanner. If this * expression contains references to local variables and it will be * compiled in an external module (not in the main class) request * the current template to create a new variable stack frame. * * @param lineNumber Line where the current expression is defined. * @param external Set to <tt>true</tt> if this expression is * compiled in a separate module. * */ public Symbol parse(String expression, int lineNumber) throws Exception { try { _expression = expression; _lineNumber = lineNumber; return super.parse(); } catch (IllegalCharException e) { ErrorMsg err = new ErrorMsg(ErrorMsg.ILLEGAL_CHAR_ERR, lineNumber, e.getMessage()); _parser.reportError(Constants.FATAL, err); } return null; }