org.apache.commons.jexl.parser
Class ASTSizeFunction

java.lang.Object
  extended byorg.apache.commons.jexl.parser.SimpleNode
      extended byorg.apache.commons.jexl.parser.ASTSizeFunction
All Implemented Interfaces:
Node

public class ASTSizeFunction
extends SimpleNode

generalized size() function for all classes we can think of

Version:
$Id: ASTSizeFunction.java,v 1.3 2003/10/09 21:28:55 rdonkin Exp $
Author:
Geir Magnusson Jr., Mark H. Wilkinson

Field Summary
 
Fields inherited from class org.apache.commons.jexl.parser.SimpleNode
children, id, parent, parser
 
Constructor Summary
ASTSizeFunction(int id)
           
ASTSizeFunction(Parser p, int id)
           
 
Method Summary
 java.lang.Object jjtAccept(ParserVisitor visitor, java.lang.Object data)
          Accept the visitor.
static int sizeOf(java.lang.Object val)
           
 java.lang.Object value(JexlContext jc)
          Returns the value of the node.
 
Methods inherited from class org.apache.commons.jexl.parser.SimpleNode
childrenAccept, dump, execute, interpret, jjtAddChild, jjtClose, jjtGetChild, jjtGetNumChildren, jjtGetParent, jjtOpen, jjtSetParent, setValue, toString, toString
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

ASTSizeFunction

public ASTSizeFunction(int id)

ASTSizeFunction

public ASTSizeFunction(Parser p,
                       int id)
Method Detail

jjtAccept

public java.lang.Object jjtAccept(ParserVisitor visitor,
                                  java.lang.Object data)
Accept the visitor.

Specified by:
jjtAccept in interface Node
Overrides:
jjtAccept in class SimpleNode

value

public java.lang.Object value(JexlContext jc)
                       throws java.lang.Exception
Description copied from class: SimpleNode
Returns the value of the node.

Overrides:
value in class SimpleNode
Throws:
java.lang.Exception

sizeOf

public static int sizeOf(java.lang.Object val)
                  throws java.lang.Exception
Throws:
java.lang.Exception