1

我正在尝试将 Web 应用程序从 Richfaces 3.3.2 迁移到 4.0.0,因此我更改了 web.xml 文件中的必要内容(servlet 映射“.xhtml”并删除了 Ajax4jsf 过滤器)。我还将richfaces 3 jar 更改为第4 个版本,但现在我遇到了一些错误,不知道如何解决它们:

The import org.ajax4jsf cannot be resolved
The import org.ajax4jsf cannot be resolved
The import org.ajax4jsf cannot be resolved
The import org.richfaces cannot be resolved
The import org.richfaces cannot be resolved
The import org.richfaces cannot be resolved
Incompatible conditional operand types UIComponent and UICalendar
UICalendar cannot be resolved to a type
HtmlToolTip cannot be resolved to a type
HtmlToolTip cannot be resolved to a type
HtmlToolTip cannot be resolved to a type
Incompatible conditional operand types UIViewRoot and AjaxViewRoot
AjaxViewRoot cannot be resolved to a type
AjaxViewRoot cannot be resolved to a type
org.ajax4jsf cannot be resolved to a type
EventsQueue cannot be resolved to a type
HtmlAjaxSupport cannot be resolved to a type
HtmlToolTip cannot be resolved to a type
Incompatible conditional operand types UIComponent and HtmlCalendar
HtmlCalendar cannot be resolved to a type
HtmlToolTip cannot be resolved to a type
HtmlToolTip cannot be resolved to a type
HtmlToolTip cannot be resolved to a type
HtmlToolTip cannot be resolved to a type
HtmlToolTip cannot be resolved to a type

有人可以帮我吗?

4

2 回答 2

0

缺少richfaces-core-impl 库

Javadoc AjaxViewRoot v4

于 2012-09-14T11:50:41.497 回答
0

删除 web.xml 文件中的 RichFaces 3.3 Ajax 过滤器

         <filter>
                <display-name>RichFaces Filter</display-name>
                <filter-name>richfaces</filter-name>
                <filter-class>org.ajax4jsf.Filter</filter-class>
          </filter>

            <filter-mapping>
                <filter-name>richfaces</filter-name>
                <servlet-name>Spring MVC Dispatcher Servlet</servlet-name>
                <dispatcher>REQUEST</dispatcher>
                <dispatcher>FORWARD</dispatcher>
                <dispatcher>INCLUDE</dispatcher>
            </filter-mapping>

RichFaces 4.0.0 最终打开 webmvc-config.xml 文件添加这个

       <bean id="flowController" class="org.springframework.webflow.mvc.servlet.FlowController">
            <property name="flowExecutor" ref="flowExecutor" />
            <property name="ajaxHandler">
                <bean class="org.springframework.faces.webflow.JsfAjaxHandler" />
            </property>
        </bean>
于 2014-01-14T06:48:51.667 回答