Examples of evaluate()


Examples of org.apache.commons.collections.Predicate.evaluate()

        CollectionUtils.filter(changes,
                               new Predicate()
                               {
                                   public boolean evaluate(Object obj)
                                   {
                                       if (predicate.evaluate(obj))
                                       {
                                           closure.execute(obj);
                                           return false;
                                       }
                                       else

Examples of org.apache.commons.el.Expression.evaluate()

        Expression arraySuffixIndex = arraySuffix.getIndex();

        Object index;
        if (arraySuffixIndex != null)
        {
            index = arraySuffixIndex.evaluate(
                    variableResolver, s_functionMapper,
                    ELParserHelper.LOGGER);
            if (index == null)
            {
                throw new PropertyNotFoundException("Index is null: "

Examples of org.apache.commons.el.ExpressionEvaluatorImpl.evaluate()

      Map options) throws ELException {
    expression = JSFELParserHelper.toJspElExpression(expression);
    ExpressionEvaluatorImpl evaluator = new ExpressionEvaluatorImpl();
    FunctionMapper mapper = new EmptyFunctionMapper();

    return evaluator.evaluate(expression, expectedClass, resolver, mapper);
  }

  class SimpleVariableResolver implements VariableResolver {
    /*
     * (non-Javadoc)
 

Examples of org.apache.commons.el.ValueSuffix.evaluate()

        List suffixes = complexValue.getSuffixes();
        int max = suffixes.size() - 1;
        for (int i = 0; i < max; i++)
        {
            ValueSuffix suffix = (ValueSuffix) suffixes.get(i);
            base = suffix.evaluate(base, variableResolver, s_functionMapper,
                ELParserHelper.LOGGER);
            if (base == null)
            {
                throw new PropertyNotFoundException("Base is null: "
                    + suffix.getExpressionString());

Examples of org.apache.commons.jelly.expression.Expression.evaluate()

        {
            ExpressionSupport expr = new ExpressionSupport()
            {
                public Object evaluate( JellyContext context )
                {
                    Object answer = jexlExpression.evaluate( context );

                    if ( answer == null )
                    {
                        answer = context.getVariable( text );

Examples of org.apache.commons.jexl.Expression.evaluate()

        msgExpression = ExpressionFactory.createExpression("log." + _filter);

        jc.getVars().put("log", notif.getMessageInfo());
        jc.getVars().put("message", notif.getMessageInfo().getMessage());

        return ((Boolean) msgExpression.evaluate(jc));
      }
      catch (Exception e)
      {
        Log.ignore(e);
      }

Examples of org.apache.commons.jexl2.Expression.evaluate()

        String result = "";

        if (StringUtils.isNotBlank(expression) && jexlContext != null) {
            try {
                Expression jexlExpression = jexlEngine.createExpression(expression);
                Object evaluated = jexlExpression.evaluate(jexlContext);
                if (evaluated != null) {
                    result = evaluated.toString();
                }
            } catch (JexlException e) {
                LOG.error("Invalid jexl expression: " + expression, e);

Examples of org.apache.commons.jxpath.CompiledExpression.evaluate()

                        jxpathContext.setLenient(oldLenient);
                    }
                } else if (compiled instanceof org.apache.commons.jexl.Expression) {
                    org.apache.commons.jexl.Expression e =
                        (org.apache.commons.jexl.Expression)compiled;
                    return e.evaluate(jexlContext);
                }
                return compiled;
            } catch (InvocationTargetException e) {
                Throwable t = e.getTargetException();
                if (t instanceof Exception) {

Examples of org.apache.commons.math.stat.descriptive.UnivariateStatistic.evaluate()

      for(int j=0;j<chemScores.size();j++) cs[j] = chemScores.get(j);
      double [] ncs = new double[nonChemScores.size()];
      for(int j=0;j<nonChemScores.size();j++) ncs[j] = nonChemScores.get(j);
      double [] as = new double[allScores.size()];
      for(int j=0;j<allScores.size();j++) as[j] = allScores.get(j);
      System.out.println(mean.evaluate(cs) + "\t" + stdev.evaluate(cs));
      System.out.println(mean.evaluate(ncs) + "\t" + stdev.evaluate(ncs));
      cmeans.add(mean.evaluate(cs));
      cstdevs.add(stdev.evaluate(cs));
      ncmeans.add(mean.evaluate(ncs));
      ncstdevs.add(stdev.evaluate(ncs));

Examples of org.apache.commons.math.stat.descriptive.moment.Mean.evaluate()

                  LocalizedFormats.DIMENSIONS_MISMATCH_SIMPLE, length, yArray.length);
        } else if (length < 2) {
            throw MathRuntimeException.createIllegalArgumentException(
                  LocalizedFormats.INSUFFICIENT_DIMENSION, length, 2);
        } else {
            double xMean = mean.evaluate(xArray);
            double yMean = mean.evaluate(yArray);
            for (int i = 0; i < length; i++) {
                double xDev = xArray[i] - xMean;
                double yDev = yArray[i] - yMean;
                result += (xDev * yDev - result) / (i + 1);
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.