You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@myfaces.apache.org by Dave <ja...@yahoo.com> on 2005/09/08 06:35:58 UTC

EL public static constant

Can EL access public static constant? For example, "#{Integer.MAX_VALUE}"

		
---------------------------------
 Click here to donate to the Hurricane Katrina relief effort.

Re: EL public static constant

Posted by Volker Weber <us...@weber-oldenburg.de>.
Hi,

no EL can't, but JSP can.

If you just need it for output you can do something like

<t:out value='<%= "Integer.MAX_VALUE = " + Integer.MAX_VALUE %>' />

or if you need the value inside of EL

<t:out value='<%= "#{" + Integer.MAX_VALUE + "}" %>' />

but it's a bit complicated to construct a valid EL expression.

Or you extend VariableResolver to handle such expressions, could be
usefull sometimes.

Regards

Dave wrote:
> Can EL access public static constant? For example, "#{Integer.MAX_VALUE}"
> 
> ------------------------------------------------------------------------
> Click here to donate to the Hurricane Katrina relief effort.
> <http://store.yahoo.com/redcross-donate3/>

-- 
Don't answer to From: address!
Mail to this account are droped if not recieved via mailinglist.
To contact me direct create the mail address by
concatenating my forename to my senders domain.