long[] numbers = {
1, 3, 4, 6, 8, 9
};
String[] strings = {
"Hello", "Goodbye"
};
Email email = new Email();
//Expression e = ExpressionFactory.createExpression("strings[1].length() < 9");
Expression e =
ExpressionFactory.createExpression("email.test == 'TEST'");
/*
* create a context and add data
*/
JexlContext jc = JexlHelper.createContext();
jc.getVars().put("numbers", numbers);
jc.getVars().put("strings", strings);
jc.getVars().put("email", email);
Object o = e.evaluate(jc);
logger.debug("result: " + o.getClass() + ", " + o);