commons-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Rahul Akolkar" <rahul.akol...@gmail.com>
Subject Re: [SCXML] Using Static methods from JEXL
Date Fri, 09 Feb 2007 21:39:08 GMT
On 2/9/07, Nestor Urquiza <nestoru@yahoo.com> wrote:
> Hi guys,
> Just wondering if someone was able to use from JEXL
> something like:
>
> <var name="foo" expr="MyClass.myStaticMethod()">
>
>
> Right now I can do:
> <var name="foo" expr="myInstance.myNonStaticMethod()">
>
> given the fact that I previously have:
> MyClass myInstance = new MyClass();
> rootCtx.set("myinstance", myinstance );
>
<snip/>

I'd expect static invocation to work similarly (will need JEXL 1.1), i.e. if:

rootCtx.set("System", System.class);

then:

<var name="currentTimeMillis" expr="System.currentTimeMillis()" />

-Rahul


> Thanks for the help in advance,
>
> -Nestor
>
>
>
>

---------------------------------------------------------------------
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