On Tue, 19 Mar 2002, John Baker wrote:

> Following on from my posts earlier (sorry it ended up going twice or
> whatever, sendmail was lieing to me), I'm wondering if I can do:
> 
> <c:set var="searchType" value="${Integer.class" scope="session/>
> 
> <c:if test="${session.searchType == Integer.class">
> 
> </c:if>
> 
> but I'm rather thinking I can't. Can anyone confirm this, and suggest
> another way?

I'm not sure what you're asking, exactly.  ${Integer.class} is a perfectly
valid expression, but it means "the 'class' property of the scoped
variable named 'Integer'".  It doesn't mean "the result of the getClass()
method for the class Integer", if that's what you're asking.

If you had an individual Integer I, then ${I.class} would correspond to
the Class object for Integer.

-- 
Shawn Bayern
Author, "JSP Standard Tag Library"  http://www.jstlbook.com
(coming this summer from Manning Publications)


--
To unsubscribe, e-mail:   <mailto:[EMAIL PROTECTED]>
For additional commands, e-mail: <mailto:[EMAIL PROTECTED]>

Reply via email to