我正在尝试开始使用 Java 和 Stripes Framework 进行开发。我的 web.xml 文件中有以下内容
<?xml version="1.0" encoding="ISO-8859-1"?>
<web-app version="2.4" xmlns="http://java.sun.com/xml/ns/j2ee" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://java.sun.com/xml/ns/j2ee http://java.sun.com/xml/ns/j2ee/web-app_2_4.xsd"
>
<filter>
<filter-name>StripesFilter</filter-name>
<filter-class>net.sourceforge.stripes.controller.StripesFilter</filter-class>
<init-param>
<param-name>ActionResolver.Packages</param-name>
<param-value>
pdapm.action
</param-value>
</init-param>
<init-param>
<param-name>Extension.Packages</param-name>
<param-value>
pdapm.extensions, org.stripesbook.reload.extensions
</param-value>
</init-param>
</filter>
<filter>
<filter-name>DynamicMappingFilter</filter-name>
<filter-class>net.sourceforge.stripes.controller.DynamicMappingFilter</filter-class>
</filter>
<filter-mapping>
<filter-name>DynamicMappingFilter</filter-name>
<url-pattern>/*</url-pattern>
<dispatcher>REQUEST</dispatcher>
<dispatcher>FORWARD</dispatcher>
<dispatcher>INCLUDE</dispatcher>
</filter-mapping>
<welcome-file-list>
<welcome-file>index.html</welcome-file>
</welcome-file-list>
</web-app>
我收到错误:
The requested resource ... is not available.
是否有任何我需要添加的内容或我应该尝试修复与 tomcat 相关的内容。我使用了 xampp 的 tomcat 插件。我是初学者,所以这可能是一个简单的错误或跳过的步骤。我只是在寻找正确方向的推动力。
[21:44:14] WARN net.sourceforge.stripes.util.ResolverUtil - Could not examine class
'pdapm/action/BaseActionBean.class' due to a java.lang.UnsupportedClassVersionError
with message: Bad version number in .class file (unable to load class
pdapm.action.BaseActionBean)
[21:44:14] WARN net.sourceforge.stripes.util.ResolverUtil - Could not examine class
'pdapm/action/HomeActionBean.class' due to a java.lang.UnsupportedClassVersionError
with message: Bad version number in .class file (unable to load class
pdapm.action.HomeActionBean)
该错误意味着您的 stripes 库是使用比 Tomcat JVM 更新的 Java 编译的。 Java 不向前兼容。假设您的 Tomcat 在 Java 5 下运行。它无法加载使用 Java 6 编译的类。
升级系统上的 JRE。
本文内容由网友自发贡献,版权归原作者所有,本站不承担相应法律责任。如您发现有涉嫌抄袭侵权的内容,请联系:hwhale#tublm.com(使用前将#替换为@)