struts-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Cohan, Sean" <>
Subject RE: Logic Equals and Interface Constants
Date Sat, 11 Jan 2003 14:12:43 GMT
There are multiple classes that build a collection which is presented on
only one jsp.  For simplicity, I'll refer to constants in the classes and
literals on the one jsp.  Then if the constants change, I only have to
change them in the interface and jsp.


-----Original Message-----
From: []
Sent: Friday, January 10, 2003 7:31 PM
Subject: Re: Logic Equals and Interface Constants

>>>>> "Sean" == Sean Cohan <Cohan> writes:

    Sean> I'd like to somehow use some final static int's defined in an
    Sean> within <logic:equal> tags.  Something like:

    Sean> <logic:equal name="columnType" value=DeltaItem.LONGTEXT>

    Sean> Can I do this or something like it (e.g., using chars instead of

You'll have to use expression scriptlets for the attribute value.  In those
expressions, you can produce any Java expression you want.

If you want/need to avoid scriptlets, then you'd have to use a more involved
process, using Struts-EL, along with a class that uses reflection to load
"static final" constants into a HashMap which can be referenced through the

David M. Karr          ; Java/J2EE/XML/Unix/C++   ; SCJP; SCWCD

To unsubscribe, e-mail:
For additional commands, e-mail:

To unsubscribe, e-mail:   <>
For additional commands, e-mail: <>

View raw message