Groovy and GWT: Combining both paradigms

爷,独闯天下 提交于 2019-12-23 08:59:50

问题


Is it possible to develop an application in groovy using GWT components?

Luis


回答1:


If you want to use Groovy on the server-side and GWT for the UI, that is certainly possible. You can use Grails (a Groovy web framework on the server), and the Grails GWT plugin to help you integrate GWT with this framework.




回答2:


I don't think so, because the GWT compiler is basically a Java to JavaScript source compiler (it would be possible if the GWT compiler needed Java bytecode). You can use Groovy on the server side though.




回答3:


Right now you cant use Groovy on the client side. One big reason is that Groovy relies a lot on introspection, and this is not available on GWT.




回答4:


I have also wondered this, as it would be very nice. Vaadin essentially does this and you can use their plugin: http://grails.org/plugin/vaadin

Doing it this model, though, it is compiling components into Javascript and delivering from the server. But unlike GWT components, these are calling back to the server every time you touch the API (though of course with Vaadin you can use GWT components as well).



来源:https://stackoverflow.com/questions/2674964/groovy-and-gwt-combining-both-paradigms

标签
易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!