Google’s Java editions

April 18th, 2009

Following the announcement of Google App Engine for Java, it’s interesting to see how Sun and Google differ in their analysis of market trends. Traditionally, Sun has three main “versions” of Java:

  • Java Standard Edition (SE) for desktop applications
  • Java Enterprise Edition (EE) for server side
  • Java Mobile Edition (ME) for phones

With JavaFX, the new (and perhaps belatedly rediscovered) focus on client side market has three versions:

  • Desktop profile
  • Mobile profile
  • TV profile

with a common profile that aims to write an application once, and have it run on all three types of displays – and the history will tell how well that will be supported and used in practice.

What about Google? This is how i see it:

  • GWT is Java Web Edition (WE)
  • Android is Java Device Edition (DE)
  • App Engine is Java Cloud Edition (CE)

and no stated goal (at least yet) to provide a common edition for GWT and Android.

A few hours ago an interesting changelist has made its way into the JDK 7 Swing branch. It definitely looks like the Nimbus designer will be available as part of JDK 7.

Unfortunately, it does look like this changelist does not contain all the files that are part of Nimbus designer (see below for the walkthrough), but hopefully this will be amended in the following days. In the meanwhile, here is what i’ve been able to do:

  • Click on the zip link on the changelist page and extract the contents of the zip file. I’ve saved it in the C:\JTools\jdk7-src folder.
  • Create a new Eclipse project. Point to C:\JTools\jdk7-src\jdk-c5cd40f1f596\make\tools\swing-nimbus\classes as source, and add all the jars in C:\JTools\jdk7-src\jdk-c5cd40f1f596\make\tools\swing-nimbus\libs as external jars.

As i said before, it looks like the changelist is not complete, and i haven’t been able to find the main class to run the designer itself. However, you can run the partial generation of Nimbus painters to get the feel of how that phase is working. Here are the steps:

Run the org.jibx.binding.Compile class passing the following two program arguments:

  • C:\JTools\jdk7-src\jdk-c5cd40f1f596\make\tools\swing-nimbus\classes\org\jdesktop\swingx\designer\Designer.jibx.xml
  • C:\JTools\jdk7-src\jdk-c5cd40f1f596\make\tools\swing-nimbus\classes\org\jdesktop\synthdesigner\synthmodel\SynthModel.jibx.xml

Copy the three .template files from C:\JTools\jdk7-src\jdk-c5cd40f1f596\src\share\classes\javax\swing\plaf\nimbus to C:\JTools\jdk7-src\jdk-c5cd40f1f596\make\tools\swing-nimbus\classes\org\jdesktop\synthdesigner\generator\resources

Run the org.jdesktop.synthdesigner.generator.Generator class passing the following arguments:

  • -full false
  • -skinFile C:\JTools\jdk7-src\jdk-c5cd40f1f596\src\share\classes\javax\swing\plaf\nimbus\skin.laf
  • -srcDir c:\temp\nimbus
  • -buildDir c:\temp\nimbus
  • -packagePrefix org.nimbus
  • -lafName Nimbus

At this point, the c:\temp\nimbus should have the generated painter classes. Note that if you pass the -full true, the generation will fail since some of the template files (such as LookAndFeel.template) are not part of this changelist.

    The third volume of Substance sightings series highlights three gaming applications powered by Substance look-and-feel. The purpose of this series is to highlight the capabilities that Substance brings to Swing applications, and you can visit the first volume published in August ’07 that featured four Swing media-oriented applications, and the second volume published in April ’08 that showcased three open-source audio players.

    The first application is WarForge which is a template builder for Warhammer Online. Here is a screenshot of WarForge under the dark Magma skin (click to see full-screen image):

    The next application is OGame Automizer – an automated bot for the OGame intergalactic conquest online browser game. Here is a screenshot of WarForge under the Nebula skin (click to see full-screen image):

    The last game is the Darkside turn-based strategy game. Here is a screenshot of WarForge under the dark Raven Graphite Glass skin (click to see full-screen image):

    If you haven’t tried Substance in your application, you’re more than welcome to do so. The current stable release is 5.1, and the next 5.2 version is available in early development drops.

    Today, i’m happy to officially announce project Amber. In works over the last few weeks, it shows how to use Trident to add animations to an online interactive application that analyzes media trends. While previous demo videos showed some of Amber’s capabilities on test data sets, this high-definition video (watch in full-screen mode) shows Amber tracking the Digg tech news trends in real time.

    To see Amber in action, click the WebStart button below and select one of the available Digg topics (last column):

    Here are a few screenshots of Amber. The login screen (fades out on pressing the “Start” button):

    The grid of story thumbnails (slide in and up):

    Infotip showing story title and description (slides and fades in):

    Another infotip, this time above the story thumbnail to fit in the frame:

    Frequency chart of keywords in the shown entries – allows to analyze the popular topics:

    The full code for Amber 1.0dev (code-named Ashberry) is available in the SVN repository, and Rémy Rakic (@lqd on Twitter) has already created a Twitter provider that allows analyzing public timelines:

    To create a custom provider, take a look at the org.pushingpixels.amber.digg.DiggProvider class. One of the next blog entries will show another provider that uses the NY Times online APIs.