With a Java background, but
having never developed for the web client side (i.e. scripts to be run by a browser),
but java applets (which I suspect being, mmm, old-fashioned (right?) or otherwise
I would clearly use them for some of the following)
then consider the following scenarios:
- Only client side application (with no server interaction).
Would you recommend to learn javascript or better to use the Google web toolkit (GWT)
(which I understand that translates java code into javascript+html)
Other choices? - BIS: A client side application interacting with another client side app (i.e. both
within a -different- browser) or with a server (standalone).
The same choices than before? I know that GWT allows remote-procedure-calls.
More? - A rich internet app.
Flex seems the usual choice (right?) I think there is no java-based language for
this (JavaFx, despite its name is not Java, and I read around “it is fatally wounded”)
Other choices? - A business application.
Then, the choice is clearly JavaEE (which includes JavaFaces for the client-side).
Really clear? Other choices?
Please correct me if I’m wrong.
It depends on the scale of the application. If it’s something that can be knocked up in a few hours with Javascript then I’d just pick that (probably using JQuery alongside.) If it’s a bigger project (some big projects are just client side!) then I’d use GWT. GWT has a higher startup cost in my experience, but once you’re going development is generally a lot nicer.
Pretty much the same as above here, though obviously this sort of interaction does point towards a more complicated program, so I’d lean towards GWT in this case.
It’s fatally wounded for the web, personally I think with the next version of JavaFX when they deprecated JavaFX script then things might look up on the desktop front. But that’s beside the point here 🙂 Flex would be a perfectly acceptable choice, however in this day and age I’d seriously consider whether HTML5 and its canvas support has everything you need (it may do or it may not depending on the application.) You’ve also got GWT available to you here as well with things such as the GWT-canvas plugin. I’ve never used it myself, but from memory it will provide backwards compatible support for browsers that don’t support HTML5 in the form of propriety plugins. If you need it to work in browsers that don’t support HTML5 then this could be a sensible option.
I’d actually lean towards Spring over JavaEE for this, I find it more flexible and far nicer to work with.