The signature of execute has changed to
public void execute(Object[] data)
Sanjiv
public void execute(Object[] data)
Sanjiv
service.callOperation("hello", data, "helloResponse", new WebServiceCallback() { @Override public void execute(Object[] data) { System.out.println("!"); Form.this.setValue("Answer", (String)data[0]); } });
Uncaught JavaScript exception [java.lang.ClassCastException: com.google.gwt.core.client.JavaScriptObject$ cannot be cast to java.lang.String at org.yournamehere.client.MainEntryPoint$Form$1.execute(MainEntryPoint.java:101) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25) at java.lang.reflect.Method.invoke(Method.java:597) at com.google.gwt.dev.shell.MethodAdaptor.invoke(MethodAdaptor.java:103) at com.google.gwt.dev.shell.ie.IDispatchImpl.callMethod(IDispatchImpl.java:126) at com.google.gwt.dev.shell.ie.IDispatchProxy.invoke(IDispatchProxy.java:155) at com.google.gwt.dev.shell.ie.IDispatchImpl.Invoke(IDispatchImpl.java:294) at com.google.gwt.dev.shell.ie.IDispatchImpl.method6(IDispatchImpl.java:194) at org.eclipse.swt.internal.ole.win32.COMObject.callback6(COMObject.java:117) at org.eclipse.swt.internal.win32.OS.DispatchMessageW(Native Method) at org.eclipse.swt.internal.win32.OS.DispatchMessage(OS.java:1925) at org.eclipse.swt.widgets.Display.readAndDispatch(Display.java:2966) at com.google.gwt.dev.GWTShell.pumpEventLoop(GWTShell.java:720) at com.google.gwt.dev.GWTShell.run(GWTShell.java:593) at com.google.gwt.dev.GWTShell.main(GWTShell.java:357)] in http://localhost:8080/HelloGWT/hosted.html?org_yournamehere_Main, line 6
public void execute(Object[] data) { Object dataVal = data[0]; System.out.println("!"); //Form.this.setValue("Answer", (String)data[0]); }
Comment