Wednesday May 23, 2012

Best Practices for JavaFX 2.0 Enterprise Applications, Part Two

Java Champion, Oracle Java Evangelist, and JavaFX expert Jim Weaver, has published Part Two of his article, "Best Practices for JavaFX 2.0 Enterprise Applications" on otn/java. Weaver continues to explore the possibilities of the TweetBrowser application, focusing now on new techniques and best practices that include:

* Leveraging a JavaFX cascading style sheet
* Implementing springs and struts in the UI
* Using a ternary operation in binding expressions
* Defining JavaFX properties
* Leveraging a Popup to implement a dialog box
* Using WebView to display a Web page

As Weaver emphasizes, there is a vast array of techniques and best practices that can be used in JavaFX applications. For example:

The JavaFX cascading style sheet (CSS) enables users to modify the appearance of an application.

The springs and struts concept enables a fixed horizontal strut and a variable horizontal spring so that an application can appear the way developers want it to appear, regardless of the size of the scene or the type of platform.

Go here to learn more about the rich possibilities of JavaFX 2.0 and enterprise applications.

Friday Mar 30, 2012

Spring to Java EE, Part Three - new tech article on otn/java

In a new article up on otn/java, Java EE expert David Heffelfinger continues his series exploring the relative strengths and weaknesses of Java EE and Spring. Here, he demonstrates how easy it is to develop the data layer of an application using Java EE, JPA, and the NetBeans IDE instead of the Spring Framework.

In the first two parts of the series, he generated a complete Java EE application by using JavaServer Faces (JSF) 2.0, Enterprise JavaBeans (EJB) 3.1, and Java Persistence API (JPA) 2.0 from Spring’s Pet Clinic MySQL schema, thus showing how easy it is to develop an application whose functionality equaled that of the Spring sample application.

In his new article, Heffelfinger tweaks the application to make it more user friendly.

From the article:
“The generated application displays primary keys on some of the pages, and these keys are surrogate primary keys—meaning that they have no business value and are used strictly as a unique identifier—so there is no reason why they should be visible to the user. In addition, we will modify some of the generated labels to make them more user-friendly.”

He concludes the article with a summary:
“The Java EE version of the application is not a straight port of the Spring version. For example, the Java EE version enables us to create, update, and delete veterinarians as well as veterinary specialties, whereas the Spring version of the application enables us only to view veterinarians and specialties. Additionally, the Spring version has a single page for managing/viewing owners, pets, and visits, whereas the Java EE version of the application has separate pages for each of these entities.
The other thing we should keep in mind is that we didn’t actually write a lot of the code and markup for the Java EE version of the application, because the bulk of it was generated by the NetBeans wizard.”

Have a look at the complete article here.

About

Insider News from the Java Team at Oracle!

duke
javeone logo
Links


Search

Archives
« April 2014
SunMonTueWedThuFriSat
  
2
5
6
7
12
13
17
18
19
20
22
24
25
26
27
28
29
30
   
       
Today