Hello there! I've just started with GWT and have this RPC Servlet:
package org.openspotlight.client;
import java.util.List;
import com.google.gwt.user.client.rpc.AsyncCallback;
import com.google.gwt.user.client.rpc.RemoteService;
public interface GWTService extends RemoteService {
public void listAvailableServices(AsyncCallback<List<String>>
callback);
}
package org.openspotlight.server;
import java.util.ArrayList;
import java.util.List;
import org.openspotlight.client.GWTService;
import org.openspotlight.parsers.Parser;
import com.google.gwt.user.client.rpc.AsyncCallback;
import com.google.gwt.user.client.rpc.SerializationException;
import com.google.gwt.user.server.rpc.RemoteServiceServlet;
public class GWTServiceImpl extends RemoteServiceServlet implements
GWTService{
private List<Parser> parsers;
@Override
public String processCall(String payload) throws
SerializationException {
Thread.currentThread().setContextClassLoader(
this.getClass().getClassLoader() );
return super.processCall(payload);
}
public void listAvailableServices(AsyncCallback<List<String>>
callback) {
List<String> services = new ArrayList<String>();
if(parsers != null){
for(Parser p : parsers){
services.add(p.getSupportedTypes());
}
}
}
}
<module>
<!-- Inherit the core Web Toolkit stuff.
-->
<inherits name='com.google.gwt.user.User'/>
<!-- Inherit the default GWT style sheet. You can change
-->
<!-- the theme of your GWT application by uncommenting
-->
<!-- any one of the following lines.
-->
<inherits name='com.google.gwt.user.theme.chrome.Chrome'/>
<!-- <inherits name='com.google.gwt.user.theme.chrome.Chrome'/>
-->
<!-- <inherits name='com.google.gwt.user.theme.dark.Dark'/>
-->
<!-- Other module inherits
-->
<!-- Specify the app entry point class.
-->
<entry-point class='org.openspotlight.client.OSLApplication'/>
<!-- Specify the application specific style sheet.
-->
<stylesheet src='OSLApplication.css' />
<servlet path="/gwtServices"
class="org.openspotlight.server.GWTServiceImpl"/>
</module>
When I run ./OSLApplication-compile, I get this error:
vinicius-carvalhos-macbook:gwt-bundle viniciuscarvalho$ ./
OSLApplication-compile
Removing units with errors
[ERROR] Errors in 'file:/Users/viniciuscarvalho/Documents/Caravela/
spotlight/gwt-bundle/src/org/openspotlight/client/OSLApplication.java'
[ERROR] Line 5: The import
org.openspotlight.server.GWTServiceImpl cannot be resolved
Compiling module org.openspotlight.OSLApplication
Computing all possible rebind results for
'org.openspotlight.client.OSLApplication'
Rebinding org.openspotlight.client.OSLApplication
Checking rule <generate-with
class='com.google.gwt.user.rebind.ui.ImageBundleGenerator'/>
[ERROR] Unable to find type
'org.openspotlight.client.OSLApplication'
[ERROR] Hint: Previous compiler errors may have made this
type unavailable
[ERROR] Hint: Check the inheritance chain from your
module; it may not be inheriting a required module or a module may not
be adding its source path entries properly
[ERROR] Build failed
I have external libs pointed using eclipse project properties, but
those libs are used in antoher class (org.openspotlight.gwt.internal)
Any ideas?
BTW: Does compile, compiles all the sources or only those at server
and client folders?
Regards
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups
"Google Web Toolkit" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to
[email protected]
For more options, visit this group at
http://groups.google.com/group/Google-Web-Toolkit?hl=en
-~----------~----~----~----~------~----~------~--~---