Fantastic, something else to learn 😉 Sun bloggers have been dropping hints to look toward the JavaOne conference in and around all of the Silverlight posts that have clogged up the aggregators the last week or so, and it appears the announcement for their new AJAX/RIA alternative comes in the form of “JavaFX”.

JavaFX makes use of a new scripting language and utilises the Swing APIs for UI. This probably comes as no suprise, I have drummed on to my poor colleagues the last year how AJAX’s days are numbered in terms of the popularity it currently enjoys, it simply cannot keep up because HTML and JS were never intended to build this “new” breed of online app, too much reliance on the browser itself naturally brings with it serious yet fully justified limitations. We’re reaching the top of that particular bell-curve now. For an example of this you just need to compare Google Docs (Google being the absolute cream of the crop in AJAX scene, yes I know they use GWT), with early pre-alpha screens of Buzzword. The potential benefits of using the Flash Player are limitless in terms of real-time document editing (binary data transfer over XML refreshes, bitmap editing, video embedding, animation creation etc). Microsoft, Sun and Adobe of course are all providing better tools to craft future of the web.

There’s also mention that JavaFX will work on mobile, another de-facto requirement for RIA technologies now. An introductory tool is due for release today, let’s hope we see a plugin for Eclipse to give it a bit of a head start there. As with AJAX and Silverlight, I’ll give it a good solid evaluation phase, I don’t think it’s fair to bash or criticize until you’ve really tried something out (and used it in a real world situation if possible). Again, I’m very much doubting the capabilities will match what Flex has to offer, but let’s keep an open mind! I’ll be very keen to see just how rapid UI development is with JavaFX over using Flex, as I’ve known people to come to Flex 2 with no previous experience, and have a fully functional app with data consumption, data binding and liquid layout working in a matter of hours.

Read the article at infoworld here.

And then there were three….

Update:

I’ve just been sent an example of JavaFX in action from Emmanuel Okyere, plus source-code:

Run the Java webstart demo here

The source-code reminds me of something between ActionScript and Processing. However this one-liner worried me a little:

for (unitinterval r in dur 1000 fps 40 while not ship.exploded
and livingAliens > 0) {

This looks fairly horrid, something like Lingo in terms of verbosity, but I imagine this is just someone playing around with dynamic dereferencing and you could break it down further or use more classic Java-style operands in place of “not”, I hope 🙂

See the complete source code for yourself here.

There’s also a video of JavaFX being used to emulate a Flash site, it shows both one after the other about half-way through.