NoClassDefFoundError:com / google / gwt / core / client / JavaScriptObject

时间:2014-07-19 15:44:37

标签: gwt google-maps-api-3 google-maps-markers vaadin

我有Vaadin的经验,但我是GWT的新手。

我尝试扩展Google Maps for Vaadin 7 add-on,它使用Google Maps API的GWT包装器,以便它可以使用Google Maps utility libraries中的Marker With Label,以便我可以添加标签标记。

因为我想避免GWT的任何继承问题,我只是更改code of the original add-on并在现有markersWithLabel属性旁边添加markers属性(我不是无论如何都需要任何多态行为),所以我的想法是我会有两组标记(一组带标签,一组没有)。

所以我在现有的GoogleMapMarker类旁边创建了一个GoogleMapMarkerWithLabel类,复制了它并添加了Marker With Label特定的属性。

我还以类似的方式创建了MarkerWithLabelMarkerWithLabelOptions,从GWT包装器复制并扩展了原始MarkerMarkerOptions。这些间接延伸com.google.gwt.core.client.JavaScriptObject

我相应地更改了GoogleMapConnector和GoogleMapWidget类,以获得2组标记,当然还是重建了我的小部件集。

我没有在其他任何地方使用这些MarkerWithLabelMarkerWithLabelOptions,但我仍然收到错误

java.lang.NoClassDefFoundError: com/google/gwt/core/client/JavaScriptObject

通常表示我尝试在服务器端使用客户端类。

我可能做错了什么?

编辑:根异常的完整服务器端堆栈跟踪:

java.lang.ClassNotFoundException: com.google.gwt.core.client.JavaScriptObject
    at org.apache.catalina.loader.WebappClassLoader.loadClass(WebappClassLoader.java:1701)
    at org.apache.catalina.loader.WebappClassLoader.loadClass(WebappClassLoader.java:1546)
    at java.lang.ClassLoader.defineClass1(Native Method)
    at java.lang.ClassLoader.defineClass(ClassLoader.java:791)
    at java.security.SecureClassLoader.defineClass(SecureClassLoader.java:142)
    at org.apache.catalina.loader.WebappClassLoader.findClassInternal(WebappClassLoader.java:2836)
    at org.apache.catalina.loader.WebappClassLoader.findClass(WebappClassLoader.java:1160)
    at org.apache.catalina.loader.WebappClassLoader.loadClass(WebappClassLoader.java:1668)
    at org.apache.catalina.loader.WebappClassLoader.loadClass(WebappClassLoader.java:1546)
    at java.lang.Class.getDeclaredMethods0(Native Method)
    at java.lang.Class.privateGetDeclaredMethods(Class.java:2442)
    at java.lang.Class.privateGetPublicMethods(Class.java:2562)
    at java.lang.Class.getMethods(Class.java:1427)
    at java.beans.Introspector.getPublicDeclaredMethods(Introspector.java:1262)
    at java.beans.Introspector.getTargetMethodInfo(Introspector.java:1123)
    at java.beans.Introspector.getBeanInfo(Introspector.java:414)
    at java.beans.Introspector.getBeanInfo(Introspector.java:161)
    at com.vaadin.server.JsonCodec$MethodProperty.find(JsonCodec.java:166)
    at com.vaadin.server.JsonCodec.getProperties(JsonCodec.java:695)
    at com.vaadin.server.JsonCodec.encodeObject(JsonCodec.java:714)
    at com.vaadin.server.JsonCodec.encode(JsonCodec.java:678)
    at com.vaadin.server.JsonCodec.encodeObjectMap(JsonCodec.java:853)
    at com.vaadin.server.JsonCodec.encodeMap(JsonCodec.java:840)
    at com.vaadin.server.JsonCodec.encode(JsonCodec.java:651)
    at com.vaadin.server.JsonCodec.encodeObject(JsonCodec.java:740)
    at com.vaadin.server.JsonCodec.encode(JsonCodec.java:678)
    at com.vaadin.server.LegacyCommunicationManager.encodeState(LegacyCommunicationManager.java:112)
    at com.vaadin.server.AbstractClientConnector.encodeState(AbstractClientConnector.java:246)
    at com.vaadin.server.communication.SharedStateWriter.write(SharedStateWriter.java:60)
    at com.vaadin.server.communication.UidlWriter.write(UidlWriter.java:127)
    at com.vaadin.server.communication.UIInitHandler.getInitialUidl(UIInitHandler.java:295)
    at com.vaadin.server.communication.UIInitHandler.synchronizedHandleRequest(UIInitHandler.java:80)
    at com.vaadin.server.SynchronizedRequestHandler.handleRequest(SynchronizedRequestHandler.java:41)
    at com.vaadin.server.VaadinService.handleRequest(VaadinService.java:1405)
    at com.vaadin.server.VaadinServlet.service(VaadinServlet.java:237)
    at javax.servlet.http.HttpServlet.service(HttpServlet.java:722)
    at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:305)
    at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:210)
    at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:224)
    at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:169)
    at org.apache.catalina.authenticator.AuthenticatorBase.invoke(AuthenticatorBase.java:472)
    at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:168)
    at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:98)
    at org.apache.catalina.valves.AccessLogValve.invoke(AccessLogValve.java:927)
    at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:118)
    at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:407)
    at org.apache.coyote.http11.AbstractHttp11Processor.process(AbstractHttp11Processor.java:987)
    at org.apache.coyote.AbstractProtocol$AbstractConnectionHandler.process(AbstractProtocol.java:579)
    at org.apache.tomcat.util.net.JIoEndpoint$SocketProcessor.run(JIoEndpoint.java:309)
    at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1110)
    at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:603)
    at java.lang.Thread.run(Thread.java:722)

0 个答案:

没有答案