commons-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Henrib <hbies...@gmail.com>
Subject Re: JEXL: status and questions
Date Sat, 06 Jun 2009 13:52:42 GMT

Howdy,

Nikhil G. Daddikar wrote:
> 
> 1. Does JEXL have any future or should I look at Commons EL?
> 
The project is in use in multiple places but it hasn't been updated for a
long time.
I'm pushing to restart the 2.0 effort & we will see soon if this gets some
traction.

Nikhil G. Daddikar wrote:
> 
> 2. What is the "return value" of a script? For example, if I evaluate 
> "a=task.id;b=task.Name; task.Name;" the result is task.id which is an 
> integer, I don't understand the logic.
> 
Could be an RFE; I suspect that creating a block will do what you expect:
"{a=task.id;b=task.Name; task.Name;}"

Nikhil G. Daddikar wrote:
> 
> 3. Is there a "return" in JEXL?
> 
No. Could be an RFE since it makes sense to break/exit loops with a given
value. However, the idea of JEXL is a simple expression evaluator, not a
full fledge language. Using Javascript (aka Rhino) might be another option.

Nikhil G. Daddikar wrote:
> 
> 4. On the syntax page it says for Scripts : Scripts can be read from a 
> String, File or URL. Can anyone elaborate?
> 
In API terms, you can create a script in Java from:
- a String variable using it as the script source.
- an URL (like "http://...") fetching the content and using it as a script
source.
- a File (like "/tmp/myscript.jexl") from your file-system using its content
as the script source.

Hope this helps.
Cheers
Henri


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




-- 
View this message in context: http://www.nabble.com/JEXL%3A-status-and-questions-tp23899160p23902130.html
Sent from the Commons - User mailing list archive at Nabble.com.


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


Mime
View raw message