1 16 17 package org.apache.commons.jexl.parser; 18 19 import org.apache.commons.jexl.JexlContext; 20 21 27 public class ASTBlock extends SimpleNode { 28 33 public ASTBlock(int id) { 34 super(id); 35 } 36 37 43 public ASTBlock(Parser p, int id) { 44 super(p, id); 45 } 46 47 48 public Object jjtAccept(ParserVisitor visitor, Object data) { 49 return visitor.visit(this, data); 50 } 51 52 58 public Object value(JexlContext context) throws Exception { 59 int numChildren = jjtGetNumChildren(); 60 Object result = null; 61 for (int i = 0; i < numChildren; i++) { 62 result = ((SimpleNode) jjtGetChild(i)).value(context); 63 } 64 return result; 65 } 66 67 } 68 | Popular Tags |