class OGNLAttributeEvaluator extends AbstractAttributeEvaluator {

    public Object evaluate(String expression, Request request) {
        if (expression == null) {
            throw new IllegalArgumentException("The expression parameter cannot be null");
        }
        try {
            return Ognl.getValue(expression, request);
        } catch (OgnlException e) {
            throw new EvaluationException("Cannot evaluate OGNL expression '"
                    + expression + "'", e);
        }
    }

}