I come from lots of Java programming and weak at JavaScript.I always used component based web-frameworks for web-application development(ZK,GWT,Wicket.etc)
Now we are planing a web+mobile application.I figured out that its better to separate bushiness-logic from UI using Spring MVC/REST/Jason combination.
Next question is mobile framework.I took a look at following frameworks
1.Sencha – Have to program in JS and it will generate HTML5 based applications.
2.Touch4J – Java Wrapper around Sencha?But whats the connections with GWT?
3.Phonegap – Have to write in JS and it will generate “hybrid” applications which runs in a web-view ? Can I host these applications in a web-server?
4.codenameone – Write in Java and it will generate native applications.(are these not hybrid applications as in PhoneGap?)
Any suggestions on this or are there any other frameworks targeting both browser and mobile application development ?
The Touch4j framework is a Java binding to the Sencha and PhoneGap APIs. The framework relies on the GWT compiler to take your Java code and translate/compile it to Javascript, just like any normal GWT application would.
Touch4j currently comes in 1 Jar file that you include in your classpath, and you basically use it like any other Java 3rd-party API. Since you are in the world of GWT, you get all the perks associated with that: GWT-RPC, debugging, Java’s type-safety, etc.
Once you have written your app you can either run it as a web app (albeit without device
support), or you can deploy it to the device. If there is anything specific that you need to do with the device, you can use the Cordova binding included in Touch4j. There are two tutorials that we have in place to do just that:
http://emitrom.com/touch4j/tutorials/hello-android
http://emitrom.com/touch4j/tutorials/hello-ios
If you want to talk to a backend Java service running in OpenShift, for example, there is a tutorial for that, too:
http://emitrom.com/touch4j/tutorials/meet-openshift
If you are a Java developer, you will feel right at home with Touch4j. Version 2.1 was released yesterday, and it includes support for ST 2.0.1 and Cordova 1.7.
Also in the interest of full disclosure, I am one of the guys behind Touch4j @ Emitrom.