0

Does anyone has experience building Mobile apps using GWT Java and HTML5?

I came across various articles yet not much useful. I am looking for a full-fledged mobile framework which should be Java based and requires no server side.

Peter Mik
  • 17
  • 2

2 Answers2

2

GWT in and itself is a good choice for mobile development, quoting GWT website:

... write AJAX applications in Java and then compile the source to highly optimized JavaScript that runs across all browsers, including mobile browsers for Android and the iPhone

As for, the server-side, GWT does not require a server side to run except for the download off-course. That is, if your app is supposed to be launched through a browser then you are all set to go. But if you are thinking of creating an off-line sort of app, then you'll need to look beyond GWT. You can still use GWT compiled scripts, but you'll need a native launcher that loads the app (in a Android WebView, for example). Writing such a launcher would not be a lot of work. This approach is good for standalone apps that don't require access to native phone APIs (camera, storage, sms etc.)

If you do require access to native phone APIs, you would need something like PhoneGap or Appcelerator Titanium. Both of these technologies allow applications written in Javascript, HTML5 and CSS to access native phone APIs. There is a project, GWT-Phonegap that lets your GWT app use phonegap APIs via GWT's java code.


eskimoblood raised a point about Titanium that as it is first compiled to Java (for android), it will not be suitable to be used with GWT. I searched for details and found that Javascript is compiled to Java byte code using Rhino JSC compiler.

Community
  • 1
  • 1
Tahir Akhtar
  • 11,385
  • 7
  • 42
  • 69
  • 1
    With Appcelerator Titanium you write JavaScript to compile the app in JAVA or Objective-C. So using it, you would write JAVA to compile to JavaScript which would compile to JAVA. So PhoneGap is the right choice to write a mobile app. – Andreas Köberle Aug 13 '11 at 12:49
  • 1
    That seems weird. Writing in dynamic language, loosing the advantages of type checking, yet to convert the latter into a strict type one - Java or Objective-C. It should be the other way around. I would rather write in strict type that compiles to JS. As such GWT seems better choice. Anyho thatnks for the help everyone. I will evaluate gwtmobile http://code.google.com/p/gwt-mobile-webkit/ and NEXT http://nextinterfaces.com – Peter Mik Aug 27 '11 at 15:53
  • Javascript to Java byte-code compilation usin Rhino JSC compiler is mostly for run-time performance reasons. Rhino can execute Javascript in interpreted or compiled mode, compile-mode being faster of the two. – Tahir Akhtar Aug 28 '11 at 09:05
0

Have you considered the Android platform? Its practically the "full-fledged (java based) mobile framework" that you're talking about.

Manish Burman
  • 3,069
  • 2
  • 30
  • 35
  • I think what he is looking for is a mobile-platform independent solution. He has iphone in his question tags – pistolPanties Aug 13 '11 at 10:18
  • Firstly, he hasn't asked for a cross platform solution. From his post, I think he was just looking to get started in developing in Java. Anyway, personally I don't think that cross platform frameworks are worth it at the moment. In most cases they're a little too sluggish/ – Manish Burman Aug 13 '11 at 15:50
  • to be honest, the question itself is very ambiguous. He wants to use GWT but require no server side (Shaking head). I will +1 this answer since Android is Java based, and require no serverside. – Rudy Aug 16 '11 at 07:48
  • I was not the one who -1'ed this answer. I think what he means by requires no server side is something exactly like GWT which can run on the browser without making a single server call after it is loaded. But I agree that question is ambiguous – pistolPanties Aug 17 '11 at 12:29
  • Sorry for the ambiguous question. I am looking for a cross-mobile web mobile framework, which should be HTML5 based and preferably Java based. I just started evaluating NEXT http://nextinterfaces.com Seems to have potential. – Peter Mik Aug 27 '11 at 15:49