commons-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From ge...@apache.org
Subject cvs commit: jakarta-commons-sandbox/jexl/src/java/org/apache/commons/jexl/parser ASTIntegerLiteral.java
Date Sat, 25 May 2002 18:39:51 GMT
geirm       02/05/25 11:39:51

  Modified:    jexl/src/java/org/apache/commons/jexl/parser
                        ASTIntegerLiteral.java
  Log:
  Support being used on the RHS of a <dot>
  
    foo.3
  
  Revision  Changes    Path
  1.2       +15 -1     jakarta-commons-sandbox/jexl/src/java/org/apache/commons/jexl/parser/ASTIntegerLiteral.java
  
  Index: ASTIntegerLiteral.java
  ===================================================================
  RCS file: /home/cvs/jakarta-commons-sandbox/jexl/src/java/org/apache/commons/jexl/parser/ASTIntegerLiteral.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- ASTIntegerLiteral.java	26 Apr 2002 04:23:14 -0000	1.1
  +++ ASTIntegerLiteral.java	25 May 2002 18:39:51 -0000	1.2
  @@ -59,7 +59,7 @@
    *  represents an integer
    *
    *  @author <a href="mailto:geirm@apache.org">Geir Magnusson Jr.</a>
  - *  @version $Id: ASTIntegerLiteral.java,v 1.1 2002/04/26 04:23:14 geirm Exp $
  + *  @version $Id: ASTIntegerLiteral.java,v 1.2 2002/05/25 18:39:51 geirm Exp $
    */
   public class ASTIntegerLiteral extends SimpleNode
   {
  @@ -80,6 +80,20 @@
       public Object jjtAccept(ParserVisitor visitor, Object data)
       {
           return visitor.visit(this, data);
  +    }
  +
  +    /**
  +     *  Part of reference resolution - wierd...  in JSTL EL you can
  +     *  have
  +     *          foo.2
  +     *  which is equiv to
  +     *          foo[2]
  +     *  it appears...
  +     */
  +    public Object execute(Object o, JexlContext ctx)
  +            throws Exception
  +    {
  +        return ASTArrayAccess.evaluateExpr(o, val);
       }
   
       public Object value(JexlContext jc)
  
  
  

--
To unsubscribe, e-mail:   <mailto:commons-dev-unsubscribe@jakarta.apache.org>
For additional commands, e-mail: <mailto:commons-dev-help@jakarta.apache.org>


Mime
View raw message