JBoss AS 7.1.1 で Mojarra 2.1.7 で PrimeFaces 3.4.2 を使用しています。
ビューを復元するときに次の例外が発生しました。
21:58:33,203 ERROR (http--127.0.0.1-8080-7) java.lang.NullPointerException
21:58:36,687 ERROR [stderr] (http--127.0.0.1-8080-7) java.lang.IllegalArgumentException: null source
21:58:36,687 ERROR [stderr] (http--127.0.0.1-8080-7) at java.util.EventObject.<init>(EventObject.java:38)
21:58:36,687 ERROR [stderr] (http--127.0.0.1-8080-7) at javax.faces.event.SystemEvent.<init>(SystemEvent.java:71)
21:58:36,703 ERROR [stderr] (http--127.0.0.1-8080-7) at javax.faces.event.ComponentSystemEvent.<init>(ComponentSystemEvent.java:73)
21:58:36,703 ERROR [stderr] (http--127.0.0.1-8080-7) at javax.faces.event.PostRestoreStateEvent.<init>(PostRestoreStateEvent.java:73)
21:58:36,703 ERROR [stderr] (http--127.0.0.1-8080-7) at com.sun.faces.lifecycle.RestoreViewPhase.deliverPostRestoreStateEvent(RestoreViewPhase.java:271)
21:58:36,703 ERROR [stderr] (http--127.0.0.1-8080-7) at com.sun.faces.lifecycle.RestoreViewPhase.execute(RestoreViewPhase.java:257)
21:58:36,703 ERROR [stderr] (http--127.0.0.1-8080-7) at com.sun.faces.lifecycle.Phase.doPhase(Phase.java:101)
21:58:36,718 ERROR [stderr] (http--127.0.0.1-8080-7) at com.sun.faces.lifecycle.RestoreViewPhase.doPhase(RestoreViewPhase.java:116)
21:58:36,718 ERROR [stderr] (http--127.0.0.1-8080-7) at com.sun.faces.lifecycle.LifecycleImpl.execute(LifecycleImpl.java:118)
21:58:36,718 ERROR [stderr] (http--127.0.0.1-8080-7) at javax.faces.webapp.FacesServlet.service(FacesServlet.java:593)
@Override
public boolean isPostback() {
assertNotReleased();
Boolean postback = (Boolean) this.getAttributes().get(POST_BACK_MARKER);
if (postback == null) {
RenderKit rk = this.getRenderKit();
if (rk != null) {
postback = rk.getResponseStateManager().isPostback(this);
} else {
// ViewRoot hasn't been set yet, so calculate the RK
ViewHandler vh = this.getApplication().getViewHandler();
String rkId = vh.calculateRenderKitId(this);
postback = RenderKitUtils.getResponseStateManager(this, rkId)
.isPostback(this);
}
this.getAttributes().put(POST_BACK_MARKER, postback);
}
return postback;
}
public String calculateRenderKitId(FacesContext context) {
Util.notNull("context", context);
Map<String,String> requestParamMap = context.getExternalContext()
.getRequestParameterMap();
String result = requestParamMap.get( // <--------- exception here !!!!!!
ResponseStateManager.RENDER_KIT_ID_PARAM);
if (result == null) {
if (null ==
(result = context.getApplication().getDefaultRenderKitId())) {
result = RenderKitFactory.HTML_BASIC_RENDER_KIT;
}
}
return result;
}
が呼び出されたときに例外が発生しました。isPostback()
これは を呼び出しますcalculateRenderKitId()
。
String result = requestParamMap.get( // <--------- exception here !!!!!!
ResponseStateManager.RENDER_KIT_ID_PARAM);
にrequestParamMap
アクセスできません。これはどのように発生し、どうすれば解決できますか?