0

这不是我第一次尝试 RPC。所有其他人都运作良好,但我不知道,为什么这不。

    public void confirmRequest(String requestId, boolean confirmWithDefault, List<String> values, final String laneId){
    AsyncCallback<Void> callback = new AsyncCallback<Void>(){
        @Override
        public void onFailure(Throwable caught)
        {
            // TODO Auto-generated method stub

        }

        @Override
        public void onSuccess(Void result)
        {
            Window.alert("jo");
            ServiceCalls.this.mainmenu.getSlidePanel().getLaneMenu().getProperLanes().get(laneId)
                    .getDefaultButton().setText("");
            statusFor();

        }

    };
    getLaneProxy().confirmRequest(requestId, confirmWithDefault, values, laneId, callback);
}

当我运行程序时,它甚至不会抛出异常。它只是没有做它应该做的事情。然后我调试了一下,发现此时抛出了 ClassNotFoundException。

AsyncCallback< Void> callback = new AsyncCallback<Void>()
4

2 回答 2

0

假设您使用的是 GWT 2.5.0,这是一个已知问题;升级到已修复的 2.5.1-rc1。

于 2013-02-07T16:16:42.320 回答
0

我有同样的问题,并在gridDragon 的帮助下找到了解决方案。我的问题是 web.xml 中的 servlet 配置错误,因此找不到我的 Impl 类。

于 2014-02-11T17:51:47.420 回答