How do I get the Eclipse + Google Plugin to create an Async interface and an Impl stub method when creating a new service method?
I work for a company that uses GWT for most of their projects and while working with Eclipse I noticed that when I add a new method to the interface *Service
(for example public Foo getFoo()
) that will automatically create an asynchronous version of that method in the interface *ServiceAsync
and create an empty stub method in the class *ServiceImpl
... Now when I work on my own projects at home using Eclipse Luna and the Google Plugin for Eclipse, I notice that this behavior is not happening. Eclipse seems to be able to notice that the Async interface is skipping the given method, but when I hit ctrl-s it doesn't auto-commit for me.
Is there a config option I am missing to add this behavior?
source to share
Check your GPE plugin settings. Go to Window β Preferences . There should be a section for the plugin under Google -> Web Toolkit -> Designer where it has settings for code style and event handlers. From the values ββthere, you can apply the same settings in another Eclipse installation.
Since you also mentioned Ctrl + S, check any settings applied when saving actions by filtering "save" in the filter text box.
If there is no use case for this generation, it might be related to a different version of the GPE plugin.
source to share
Make sure you have enabled GWT in the properties of the project that has classes *Service
: Project
β Properties
β Google
β Web Toolkit
β Use Google Web Toolkit
. This will allow you to use function sync services and their async versions.
As for automatically performing the save operation, you can set it to Window
β Preferences
β Java
β Editor
β Save Actions
. But I don't see anything there that will allow the behavior you desire. Maybe you can cross-check what you got there with your Eclipse config at work?
source to share