日期:2014-05-18  浏览次数:20637 次

jsf错误急
HTTP Status 500 - 

--------------------------------------------

type Exception report

message 

description The server encountered an internal error () that prevented it from fulfilling this request.

exception 

javax.servlet.ServletException: #{user.show}: javax.faces.el.MethodNotFoundException: show: java.util.TreeMap.show()
javax.faces.webapp.FacesServlet.service(FacesServlet.java:209)
org.netbeans.modules.web.monitor.server.MonitorFilter.doFilter(MonitorFilter.java:368)


root cause 

javax.faces.FacesException: #{user.show}: javax.faces.el.MethodNotFoundException: show: java.util.TreeMap.show()
com.sun.faces.application.ActionListenerImpl.processAction(ActionListenerImpl.java:74)
javax.faces.component.UICommand.broadcast(UICommand.java:312)
javax.faces.component.UIData.broadcast(UIData.java:657)
javax.faces.component.UIViewRoot.broadcastEvents(UIViewRoot.java:267)
javax.faces.component.UIViewRoot.processApplication(UIViewRoot.java:381)
com.sun.faces.lifecycle.InvokeApplicationPhase.execute(InvokeApplicationPhase.java:75)
com.sun.faces.lifecycle.LifecycleImpl.phase(LifecycleImpl.java:200)
com.sun.faces.lifecycle.LifecycleImpl.execute(LifecycleImpl.java:90)
javax.faces.webapp.FacesServlet.service(FacesServlet.java:197)
org.netbeans.modules.web.monitor.server.MonitorFilter.doFilter(MonitorFilter.java:368)


note The full stack trace of the root cause is available in the Apache Tomcat/5.5.17 logs.

弄表界面
  <f:view>
  <h:form>
  <center>
  <h:dataTable title="用户信息" bgcolor="red" var="user" value="#{user.all}" border="1" width="80%">
  <h:column>
  <f:facet name="header">
  <h:outputText value="编号">
  </h:outputText>
  </f:facet>
  <h:outputText value="#{user.id}">
  </h:outputText>
  </h:column>

  <h:column>
  <f:facet name="header">
  <h:outputText value="用户名">
  </h:outputText>
  </f:facet>
  <h:outputText value="#{user.name}">
  </h:outputText>
  </h:column>

  <h:column>
  <f:facet name="header">
  <h:outputText value="密码">
  </h:outputText>
  </f:facet>
  <h:outputText value="#{user.pwd}">
  </h:outputText>
  </h:column>

  <h:column>
  <f:facet name="header">
  <h:outputText value="修改"></h:outputText>
  </f:facet>
  <h:commandLink action="