Jasper in turn uses JDT to compile JSPs into servlets and JDT is currently only JDK 1.4 compliant. To use 1.5 features in your JSP you will thus have to replace jasper.
This questions has been brought up a couple of times so search the archives or look at http://tomcat.apache.org/tomcat-5.5-doc/jasper-howto.html Regards Thomas Dola Woolfe <[EMAIL PROTECTED]> 11-01-2006 01:07 Besvar venligst til "Tomcat Users List" Til: Tom Cat <tomcat-user@jakarta.apache.org> cc: Vedr.: Tomcat 5.5 and java 1.5 features. Hi, I'd like to use java 1.5 features in my jsp code, in particular generics. But the jasper compiler really doesn't like it. Any setting to fix this: org.apache.jasper.JasperException: Unable to compile class for JSP An error occurred at line: 2 in the jsp file: /MBInit.jsp Generated servlet error: The method name() is undefined for the type Object An error occurred at line: 2 in the jsp file: /MBInit.jsp Generated servlet error: Type mismatch: cannot convert from Object to Message An error occurred at line: 2 in the jsp file: /MBInit.jsp Generated servlet error: Type mismatch: cannot convert from Object to Vector org.apache.jasper.compiler.DefaultErrorHandler.javacError(DefaultErrorHandler.java:84) org.apache.jasper.compiler.ErrorDispatcher.javacError(ErrorDispatcher.java:328) org.apache.jasper.compiler.JDTCompiler.generateClass(JDTCompiler.java:397) org.apache.jasper.compiler.Compiler.compile(Compiler.java:288) org.apache.jasper.compiler.Compiler.compile(Compiler.java:267) org.apache.jasper.compiler.Compiler.compile(Compiler.java:255) org.apache.jasper.JspCompilationContext.compile(JspCompilationContext.java:556) org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:293) org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:291) org.apache.jasper.servlet.JspServlet.service(JspServlet.java:241) javax.servlet.http.HttpServlet.service(HttpServlet.java:802) Many thanks in advance! Dola __________________________________________________ Do You Yahoo!? Tired of spam? Yahoo! Mail has the best spam protection around http://mail.yahoo.com --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] <FONT SIZE=1 FACE="Arial">_______________ Vi goer opmaerksom paa, at denne e-mail kan indeholde fortrolig information. Hvis du ved en fejltagelse modtager e-mailen, beder vi dig venligst informere afsender om fejlen ved at bruge svar-funktionen. Samtidig beder vi dig slette e-mailen i dit system uden at videresende eller kopiere den. Selv om e-mailen og ethvert vedhaeftet bilag efter vores overbevisning er fri for virus og andre fejl, som kan paavirke computeren eller it-systemet, hvori den modtages og laeses, aabnes den paa modtagerens eget ansvar. Vi paatager os ikke noget ansvar for tab og skade, som er opstaaet i forbindelse med at modtage og bruge e-mailen. _______________ Please note that this message may contain confidential information. If you have received this message by mistake, please inform the sender of the mistake by sending a reply, then delete the message from your system without making, distributing or retaining any copies of it. Although we believe that the message and any attachments are free from viruses and other errors that might affect the computer or IT system where it is received and read, the recipient opens the message at his or her own risk. We assume no responsibility for any loss or damage arising from the receipt or use of this message. </FONT>