On 3/23/06, David M Sledge <[EMAIL PROTECTED]> wrote:
> Do EL expressions only evaluate to String and primitive types?  I have code
> similar to the following in my jsp.
>
> <logic:iterate name="uriList" id="uri">
>
>  <write:iterate name=" uriValueMap" property="${uri}"/>
>
<snip/>

I will assume thats bean:write.


> </logic:iterate>
>
>
> Where uriList is an object of type java.util.List only containing
> java.net.URI objects, and where uriValueMap has only java.net.URI objects as
> keys and has for values objects with the property someProperty.
>
>
> As a result, I end up getting the following exception:
>
> javax.servlet.ServletException: Invalid argument looking up property:
> "http://namespace-uri.org.someProperty"; of bean: "uriValueMap"
>
> Is there any way to preserved the java.net.URI type as a lookup key?
>
<snap/>

Probably not using bean:write. I prefer JSTL counterparts for the tags
above. This will work:

<c:forEach items="${uriList}" var="uri">
  <c:out value="${uriValueMap[uri]}" />
</c:forEach>

c:out may not be needed.

-Rahul


>
>
> Thanks,
>
>
>
> David M. Sledge
>
> Analyst/Programmer Specialist
>
> LTER Network Office
>
> Dept. of Biology, MSC03 2020
> 1 University of New Mexico
> Albuquerque, NM  87131-0001
>
> 505-277-0666
> [EMAIL PROTECTED]
>
>
>
>
>

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

Reply via email to