commons-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Dion Gillard <dion.gill...@gmail.com>
Subject Re: Jexl if statement
Date Sun, 03 Apr 2005 07:42:35 GMT
On Apr 3, 2005 4:34 PM, Misha Stankovic <misha5@optusnet.com.au> wrote:
> Hi,
> 
> Could someone clarify for me please whether the jexl library supports if
> statements.

It does not.

> It appears that theere is a placeholder for this statement in the language
> syntax, but the statement does not seem to be implemented.

Correct. The grammar has it defined, but it is not implemented in the code.

> Whenever I tried creating expressions with the syntax
> 
>     if( expression ) statement;
> 
> I get an exception:
> 
> Invalid Expression: neither Reference nor Expression
> at
> org.apache.commons.jexl.ExpressionFactory.createNewExpression(ExpressionFact
> ory.java:134)
> at
> org.apache.commons.jexl.ExpressionFactory.createExpression(ExpressionFactory
> .java:94)
> at test.JexlTest.testIfElse(JexlTest.java:53)
> at junit.extensions.TestDecorator.basicRun(TestDecorator.java:22)
> at junit.extensions.TestSetup$1.protect(TestSetup.java:19)
> at junit.extensions.TestSetup.run(TestSetup.java:23)
> at test.JexlTest.main(JexlTest.java:82)
> 
> Thanks
> Misha
-- 
http://www.multitask.com.au/people/dion/

---------------------------------------------------------------------
To unsubscribe, e-mail: commons-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: commons-user-help@jakarta.apache.org


Mime
View raw message