Friday, November 28, 2008

Planning On Using JavaFX ......

Java is a verbose language, and creating inner classes to serve as poor man's lambdas also creates space-time discontinuities for somebody who had explosure to functional programming languages. So I begin to wonder if I could plug in some "lightweight" language for rapid development today, especially for the GUI staff, where callbacks (with countless lovely little classes) are a norm.

Clojure, Scala and Groovy are all on my list. While personally I would prefer a language like Clojure for playing with (as it is a modern lisp!), it is not a valid option because in the REAL WORLD (tm) not too many people love endless parentheses. And both Scala and Groovy has pros and cons, so it's a bit hard to deside.

Then I found a page mentioning JavaFX. I remember coming across the very name months ago, and all that "RIA war" stuff. I was not a GUI guy and not interested in RIA much, but as long as I could see I also didn't believe JavaFX can beat its opponents. Then for a long time the JavaFX thing was not mentioned often, I almost thought it was dead.

After all, Sun is great on inventing but not on marketing, as many say. But then why is Java itself a big success? There are people who hate the "Java brings GC and bytecode to the world" hype just as they hate the "Microsoft invents everything" one, no?

And the good (or bad?) news is, JavaFX isn't dead.

The first release version will be shipped on Dec 4, that is a week from now.

It is said to be a DSL for RIA, or an evolution of the Java Platform towards its future. Anyway, the most important thing is, JavaFX is a lightweight declarative wrapper for Swing and a functional-style wrapper for Java the language, which is exactly the thing I am looking for. Syntax sugars aren't always sweet but it greatly helps when you have just enough.

I cannot comment on the heavy SQL-like syntex regarding JavaFX's collection operations as I have not actually used them already, but considering the C# clowds seem rather excited with LINQ, it may be an interesting way to write applications.

I will check it out and hope the lovely little classes are no more.

Closures, not the poor man's one.

No comments: