eclipse IDE for enterprise java developers版本2020-03(4.15.0)导入一个别人给我的javaweb项目无法编译一直报图示错误
Stacktrace:] with root cause
org.apache.jasper.JasperException: Unable to compile class for JSP:
org.apache.jasper.JasperException: Unable to compile class for JSP:
An error occurred at line: [53] in the generated java file: [C:\Users\CXW\eclipse-workspace\.metadata\.plugins\org.eclipse.wst.server.core\tmp0\work\Catalina\localhost\center-union\org\apache\jsp\index_jsp.java]
The method getDispatcherType() is undefined for the type HttpServletRequest
经过一天多研究发现是项目自带了servlet-api.jar和tomcat8冲突导致,项目原来是tomcat6没有这个问题,把项目自带的servlet-api.jar包删除后刷新编译解决