当我使用
时<ui:include src="File.xhtml">
<ui:param name="anexoTarefaBeanEspecializado" value="#{myBean}"/>
</ui:include>
这个代码在ui:composition on&#34; File.xhtml&#34;
中<t:saveState value="#{anexoTarefaBeanEspecializado.anexoTarefaSecao}" />
myBean拥有属性&#34; anexoTarefaSecao&#34;填充了getter和setter。
然后我向页面发出请求,它正确加载。 但是当我在页面另一部分的按钮中发出请求时,我得到了这个期望:
Caused by: java.lang.IllegalArgumentException: can't parse argument number anexoTarefaBeanEspecializado.anexoTarefaSecao
at java.text.MessageFormat.makeFormat(MessageFormat.java:1339) ~[na:1.6.0_29]
at java.text.MessageFormat.applyPattern(MessageFormat.java:458) ~[na:1.6.0_29]
at java.text.MessageFormat.<init>(MessageFormat.java:350) ~[na:1.6.0_29]
at java.text.MessageFormat.format(MessageFormat.java:811) ~[na:1.6.0_29]
at com.sun.faces.util.MessageUtils.getExceptionMessageString(MessageUtils.java:395) ~[jsf-impl-2.0.6.jar:2.0.6-FCS]
at com.sun.faces.application.view.StateManagementStrategyImpl$1.visit(StateManagementStrategyImpl.java:268) ~[jsf-impl-2.0.6.jar:2.0.6-FCS]
at com.sun.faces.component.visit.FullVisitContext.invokeVisitCallback(FullVisitContext.java:151) ~[jsf-impl-2.0.6.jar:2.0.6-FCS]
at javax.faces.component.UIComponent.visitTree(UIComponent.java:1485) ~[jsf-api-2.0.6.jar:2.0.6-FCS]
at javax.faces.component.UIComponent.visitTree(UIComponent.java:1499) ~[jsf-api-2.0.6.jar:2.0.6-FCS]
at javax.faces.component.UIComponent.visitTree(UIComponent.java:1499) ~[jsf-api-2.0.6.jar:2.0.6-FCS]
at org.richfaces.component.AbstractTogglePanel.visitTree(AbstractTogglePanel.java:745) ~[richfaces-components-ui-4.2.3.Final.jar:4.2.3.Final]
at javax.faces.component.UIComponent.visitTree(UIComponent.java:1499) ~[jsf-api-2.0.6.jar:2.0.6-FCS]
at javax.faces.component.UIForm.visitTree(UIForm.java:335) ~[jsf-api-2.0.6.jar:2.0.6-FCS]
at javax.faces.component.UIComponent.visitTree(UIComponent.java:1499) ~[jsf-api-2.0.6.jar:2.0.6-FCS]
at javax.faces.component.UIComponent.visitTree(UIComponent.java:1499) ~[jsf-api-2.0.6.jar:2.0.6-FCS]
at com.sun.faces.component.visit.VisitUtils.doFullNonIteratingVisit(VisitUtils.java:75) ~[jsf-impl-2.0.6.jar:2.0.6-FCS]
at com.sun.faces.application.view.StateManagementStrategyImpl.restoreView(StateManagementStrategyImpl.java:257) ~[jsf-impl-2.0.6.jar:2.0.6-FCS]
at com.sun.faces.application.StateManagerImpl.restoreView(StateManagerImpl.java:181) ~[jsf-impl-2.0.6.jar:2.0.6-FCS]
at com.sun.faces.application.view.ViewHandlingStrategy.restoreView(ViewHandlingStrategy.java:123) ~[jsf-impl-2.0.6.jar:2.0.6-FCS]
at com.sun.faces.application.view.FaceletViewHandlingStrategy.restoreView(FaceletViewHandlingStrategy.java:448) ~[jsf-impl-2.0.6.jar:2.0.6-FCS]
at com.sun.faces.application.view.MultiViewHandler.restoreView(MultiViewHandler.java:148) ~[jsf-impl-2.0.6.jar:2.0.6-FCS]
at javax.faces.application.ViewHandlerWrapper.restoreView(ViewHandlerWrapper.java:288) ~[jsf-api-2.0.6.jar:2.0.6-FCS]
at com.sun.faces.lifecycle.RestoreViewPhase.execute(RestoreViewPhase.java:187) ~[jsf-impl-2.0.6.jar:2.0.6-FCS]
at com.sun.faces.lifecycle.Phase.doPhase(Phase.java:101) ~[jsf-impl-2.0.6.jar:2.0.6-FCS]
at com.sun.faces.lifecycle.RestoreViewPhase.doPhase(RestoreViewPhase.java:111) ~[jsf-impl-2.0.6.jar:2.0.6-FCS]
at com.sun.faces.lifecycle.LifecycleImpl.execute(LifecycleImpl.java:118) ~[jsf-impl-2.0.6.jar:2.0.6-FCS]
at javax.faces.webapp.FacesServlet.service(FacesServlet.java:508) ~[jsf-api-2.0.6.jar:2.0.6-FCS]
答案 0 :(得分:0)
此错误消息不明确。但通常在saveState上使用的参数未正确传递时会发生此错误。
干杯;