Java Champion / JavaOne Rockstar Adam Bien (adam-bien.com) is a self-employed consultant, lecturer, software architect, developer, and author in the enterprise Java sector. He is also the author of several books and articles on Java and Java EE technology, as well as distributed Java programming. adam has posted 59 posts at DZone. View Full User Profile

Is JavaFX Ready For The Enterprise? Or Why Should You Care (11 Questions and Answers)

03.26.2010
| 4281 views |
  • submit to reddit
  1. Easy start
  2. Starting with Java FX is surprisingly easy. You can build your first application in minutes. There are many "hello world" tutorials out there. That is important for the first impression and so adoption. The tutorials, however, are more focussed on visual effects and less on clean application structure, patterns and code organization.
  3. Good IDE support
  4. The plain IDE support (e.g. editing experience) is still not as good as Java. You get basic refactorings like e.g. renaming methods, classes and packages, moving artifacts etc. More sophisticated refactorings like e.g. extract method, extract attribute, quick fix etc. are still not available. The tool support right now is, however, orders of magnitude better than it was at the beginning of Java (around JDK 1.2-1.3).
  5. Unit test integration
  6. Junit 3 can be used easily to test your components. You only have to integrated the library and run the test. It is, however, not as seemless integrated to your IDE, as it is the case in Java (e.g. no green bar).
  7. Continuous integration support
  8. You can already build Java FX with ANT (standard in NetBeans 6.8) and Maven therefore you can also easily use e.g. hudson to run continuous builds. There is still work to be done.
  9. Books, tutorials, docs and online resources available
  10. There are a lot of resources out there. Most of them go far beyond "hello world" and simple applications. The amount and quality is still not comparable with e.g. Swing - but is amazing for such young technology. So far I was able to find answers to the majority of my open questions.
  11. Support for form based applications. They are still typical in the enterprise
  12. Building Java FX forms is easy. Even without any WYSIWYG support, manually with simple VBox / HBox containers. NetBeans 6.8 comes with a visual designer (composer), which allows the composition of visual components in WYSIWYG way.
  13. Easy to use visual components
  14. The current version (1.2) is lacking more complex controls, what will be fixed in the 1.3 version. Table controls will be available after the 1.3 release. Tables are crucial, but you can still easily integrate Swing JTables without any effort. The only caveat - you will have to code the TableModels probably in Java.
  15. Easy integration with "legacy" Java world
  16. The Java FX -> Java integration is seamless and works well. The Java -> Java FX integration is possible but not well defined yet.
  17. Support for remoting - remote protocols
  18. Java FX comes with good HTTP, REST / XML support. You can invoke instantiate and invoke Java classes directly from Java FX, so you can use whatever you want from Java FX - from CORBA to Hessian
  19. RCP / Java integration
  20. NetBeans engineers are working on an interesting idea - you will be able to implement whole RCP applications with plain Java FX.
  21. Productivity
  22. Java FX comes with closures and functional aspects - you can save a lot of code, comparing it to Swing / JFace development. You don't have to implement interfaces as listeners and just register your functions (methods). Binding, triggers and the functional capabilities allow you to build enterprise UIs with a fraction of the in Java necessary code. Model View Presenter patterns are easy to implement. You don't need any framework for data binding. It comes with the language. You can reuse any Java business logic and integrate it with Java FX.

Whether Java FX is ready or not, it mainly depends on the team spirit. If you are a passionated developer and want to learn something new - go for it. Because it is new technology you should also expect minor problems and should be ready to implement some workarounds etc. I remember a project in the early JDK 1.1 - 1.2 timeframe. We evaluated JFC (Java Foundation Classes, aka Swing). It was an alpha or beta release and we had even trouble with JTextField (it wasn't rendered properly). My experience with Java FX is a lot better, than it was with Java < 1.3 :-). Also important is Oracle's commitment to Java FX. See also my Java FX interview at java.sun.com.

From http://www.adam-bien.com/roller/abien/entry/is_javafx_ready_for_the

Published at DZone with permission of its author, adam bien.

(Note: Opinions expressed in this article and its replies are the opinions of their respective authors and not those of DZone, Inc.)

Tags:

Comments

Nabeel Manara replied on Fri, 2012/01/27 - 8:55am

I just started exploring JavaFX and I like it because I can integrate java stuff I did and have a great looking interface. But most importantly the learning curve is steep. It is fun building things with it. And other than with Flash and Flex, I can go on using my IDE and tools I became to like over time.

Comment viewing options

Select your preferred way to display the comments and click "Save settings" to activate your changes.