Bracket Problems

Hi,

I am new to JSP and am trying to get this bit of code to work that I know is fine in a normal java class

Arrays.sort(fields, new Comparator<String[]>() { etc...

It does not seem to like running it and I think its because of the <String[]> part...

Any ideas.. reading other topics; do I have to use something like <%=String%>

Thanks

[381 byte] By [houseofwraitha] at [2007-11-27 11:35:56]
# 1

What server are you using? What version?

What version of Java do you have?

If it is Tomcat5.5, I think by default it compiles with the Eclipse JDT compiler.

However that is only Java1.4 compliant. To use the new Java1.5 features in your JSP pages you need to change the settings of Tomcat to use the standard compiler.

You do that by configuring the init parameters in $CATALINA_BASE/conf/web.xml

http://tomcat.apache.org/tomcat-5.5-doc/jasper-howto.html#Configuration

Cheers,

evnafets

evnafetsa at 2007-7-29 17:05:47 > top of Java-index,Enterprise & Remote Computing,Web Tier APIs...