Wicket, WicketComponent
locrianmode Apr 17, 2009 10:15 AMHi,
I am getting an error in my Seam/Wicket application.
public class TimesheetApplication extends SeamWebApplication {
.
.
.
@Override
public RequestCycle newRequestCycle(final Request request, final Response response) {
return new SeamWebRequestCycle(this, (WebRequest) request, (WebResponse) response) {
@Override
public Page onRuntimeException(Page page, RuntimeException e) {
return new CustomeExceptionPage(e);
}
};
}
}I will get the errors if I try override methods in the SeamWebRequestCycle, even just putting an empty curly brackets gives the error
@Override
public RequestCycle newRequestCycle(final Request request, final Response response) {
return new SeamWebRequestCycle(this, (WebRequest) request, (WebResponse) response)
{}; // <--------
}|SEVERE: Servlet.service() for servlet jsp threw exception java.lang.NullPointerException at org.jboss.seam.wicket.WicketComponent.<init>(WicketComponent.java:171) at com.smoe.timesheet.web.wicket.TimesheetApplication$1.<clinit>(TimesheetApplication.java) at com.smoe.timesheet.web.wicket.TimesheetApplication.newRequestCycle100(TimesheetApplication.java:43) at com.smoe.timesheet.web.wicket.TimesheetApplication.newRequestCycle(TimesheetApplication.java) at org.apache.wicket.protocol.http.WicketFilter.doGet(WicketFilter.java:351) at org.apache.wicket.protocol.http.WicketFilter.doFilter(WicketFilter.java:201) at org.jboss.seam.web.WicketFilter.doFilter(WicketFilter.java:132) at org.jboss.seam.servlet.SeamFilter$FilterChainImpl.doFilter(SeamFilter.java:69) at org.jboss.seam.servlet.SeamFilter.doFilter(SeamFilter.java:158) |
Everything is fine if I just do this ...
@Override
public RequestCycle newRequestCycle(final Request request, final Response response) {
return new SeamWebRequestCycle(this, (WebRequest) request, (WebResponse) response);
}Any pointers? Thanks.