Examples of ExpressionEvaluatorImpl


Examples of org.apache.commons.el.ExpressionEvaluatorImpl

        return ee.evaluate(expression, expectedType, getVariableResolver(actionForm, request, servletContext), null);
    }

    private static final ExpressionEvaluator getExpressionEvaluator()
    {
        return new ExpressionEvaluatorImpl();
    }
View Full Code Here

Examples of org.apache.commons.el.ExpressionEvaluatorImpl

    /**
     * Constructor.
     */
    public ELEvaluator() {
        ee = new ExpressionEvaluatorImpl();
    }
View Full Code Here

Examples of org.apache.commons.el.ExpressionEvaluatorImpl

     *
     * @param fnMapper The function mapper for this Evaluator.
     * @see javax.servlet.jsp.el.FunctionMapper
     */
    public ELEvaluator(final FunctionMapper fnMapper) {
        ee = new ExpressionEvaluatorImpl();
        this.fnMapper = fnMapper;
    }
View Full Code Here

Examples of org.apache.commons.el.ExpressionEvaluatorImpl

     *
     * @return Log The log being used.
     */
    private ExpressionEvaluator getEvaluator() {
        if (ee == null) {
            ee = new ExpressionEvaluatorImpl();
        }
        return ee;
    }
View Full Code Here

Examples of org.apache.commons.el.ExpressionEvaluatorImpl

                throw ValidationException.required(nameText, "Please enter a name.");
            }
            if ((uriText.getText().length() == 0) && !editingDefault) {
                throw ValidationException.required(uriText, "Please enter a URL.");
            }
            ExpressionEvaluator eval = new ExpressionEvaluatorImpl();
            try {
                eval.evaluate((String) nameText.getText(), String.class, new DefaultVariables(),
                              StaticFunctionMapper.getDefault());
            } catch (Exception e) {
                throw ValidationException.invalid(nameText, "Error evaluating EL expression:\n" + e.getMessage());
            }
            try {
                eval.evaluate((String) uriText.getText(), String.class, new DefaultVariables(),
                              StaticFunctionMapper.getDefault());
            } catch (Exception e) {
                throw ValidationException.invalid(uriText, "Error evaluating EL expression:\n" + e.getMessage());
            }
View Full Code Here

Examples of org.apache.commons.el.ExpressionEvaluatorImpl

    }

    public void actionPerformed(ActionEvent ev) {
      try {
        StaticFunctionMapper functionMapper = StaticFunctionMapper.getDefault();
        ExpressionEvaluator eval = new ExpressionEvaluatorImpl();
        VariableResolver resolver = new DefaultVariables(uriText.getText(), null, null);
        resultText.setText((String) eval.evaluate(elText.getText(), String.class, resolver, functionMapper));
      } catch (ELException e) {
        ExceptionDialog.show(TestingTool.this, e);
      }
    }
View Full Code Here

Examples of org.apache.commons.el.ExpressionEvaluatorImpl

    this.log = log;
  }

  // JavaDoc inherited
  public void handle(String data, ContentHandler handler) {
    ExpressionEvaluator evaluator = new ExpressionEvaluatorImpl();
    Object value;
    try {
      value = evaluator.evaluate(data, Object.class, resolver, mapper);
      if (value != null) {
        char[] result = value.toString().toCharArray();
        handler.characters(result, 0, result.length);
      } else {
        log.debug("Failed to resolve " + data);
View Full Code Here

Examples of org.apache.commons.el.ExpressionEvaluatorImpl

        this.log = log;
    }

    // JavaDoc inherited
    public void handle(String data, ContentHandler handler) {
        ExpressionEvaluator evaluator = new ExpressionEvaluatorImpl();
        Object value;
        try {
            value = evaluator.evaluate(data, Object.class, resolver, mapper);
            char[] result = value.toString().toCharArray();
            handler.characters(result, 0, result.length);
        } catch (ELException ele) {
            log.error("Failed to handle EL expression.", ele);
        } catch (SAXException saxe) {
View Full Code Here

Examples of org.apache.commons.el.ExpressionEvaluatorImpl

   *
   * @param data DOCUMENT ME!
   * @param handler DOCUMENT ME!
   */
  public void handle(String data, ContentHandler handler) {
    ExpressionEvaluator evaluator = new ExpressionEvaluatorImpl();
    Object value;

    try {
      value = evaluator.evaluate(data, Object.class, resolver, mapper);

      if (value != null) {
        char[] result = value.toString().toCharArray();
        handler.characters(result, 0, result.length);
      } else {
View Full Code Here

Examples of org.apache.jasper.el.ExpressionEvaluatorImpl

   * Provides programmatic access to the ExpressionEvaluator. The JSP
   * Container must return a valid instance of an ExpressionEvaluator that can
   * parse EL expressions.
   */
  public ExpressionEvaluator getExpressionEvaluator() {
    return new ExpressionEvaluatorImpl(this.applicationContext.getExpressionFactory());
  }
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.