Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.
Comment: Migrated to Confluence 5.3

Table of Contents
outlinetrue

Overview

Griffon 1.3.0 - is the latest release in the 1.x series

Dependencies

The following dependencies have been upgraded

  • groovy-all 2.1.3
  • ant 1.9.0
  • ant-launcher 1.9.0
  • ant-junit 1.9.0
  • http-builder 0.6
  • slf4j-api 1.7.3
  • slf4j-log4j12 1.7.3
  • jcl-over-slf4j 1.7.3
  • jul-to-slf4j 1.7.3
  • org.springframework.beans 3.2.2.RELEASE
  • org.springframework.context 3.2.2.RELEASE
  • org.springframework.context.support 3.2.2.RELEASE
  • org.springframework.core 3.2.2.RELEASE

Features

Buildtime

Uninstall Dependent Plugins

Sometimes, when installing a particular plugin A other plugins get installed too. However when uninstalling plugin A its dependencies remain, that is, uninstalling lookandfeel will leave miglayout installed in the application. Now, there's a new flag that can be used to force the removal of a plugin plus all of its dependent plugins. Say you'd like to remove both lookandfeel with all of its dependent plugins with one single command, here's how it can be done

Code Block
languagegroovy
griffon uninstall-plugin lookandfeel --force

Dependent plugins will be uninstalled as long as no other plugin requires them. Take for example an application that has dialogs, lookandfeel and miglayout plugins installed. Both dialogs and lookandfeel depend on miglayout. Invoking the previous command will uninstall lookandfeel alone as dialogs still requires miglayout.

Plugin Dependencies Report

Griffon 1.3.0 includes a new command (plugin-dependencies-report) that displays a dependencies graph of all installed plugins. Plugin dependencies use the following prefix characters to identify their state

  •  . the artifact is installed
  •  + the artifact will be installed
  •  - the artifact will be removed or was evicted in favor of a more recent version
  •  ? the artifact could not be resolved
  •  ! the artifact has conflicting versions

For example given the following plugins definitions in application.properties

Code Block
languagegroovy
plugins.glazedlists=2.0.0
plugins.lookandfeel=1.0.0
plugins.miglayout=1.0.0
plugins.swing=1.3.0

Dependency Graph Report

As part of running the dependency-report command Griffon will now display a Gradle inspired dependency graph for all configurations.

Runtime

Reference Keys for Messages and Resources

There may be times where you would want to have a 2 keys reference the same value, as if one key were an alias for the other. MessageSource and ResourceResolver support the notion of referenced keys for this matter. In order to achieve this, the value of the alias key must define the aliased key with a special format, for example

Code Block
languagegroovy
famous.quote = This is {0}!
hello.world = @[famous.quote]

Resolving those keys results in

Code Block
languagegroovy
assert app.getMessage('famous.quote', ['Sparta']) == 'This is Sparta!'
assert app.getMessage('hello.world', ['Griffon']) == 'This is Griffon!'

Property Editors for Basic Types

The list of default PropertyEditors that Griffon can handle has grown to the following

  •  java.lang.String -> griffon.core.resources.editors.StringPropertyEditor
  •  java.io.File -> griffon.core.resources.editors.FilePropertyEditor
  •  java.net.URL -> griffon.core.resources.editors.URLPropertyEditor
  •  java.net.URI -> griffon.core.resources.editors.URIPropertyEditor
  •  java.math.BigDecimal -> griffon.core.resources.editors.BigDecimalPropertyEditor
  •  java.math.BigInteger -> griffon.core.resources.editors.BigIntegerPropertyEditor
  •  java.lang.Boolean -> griffon.core.resources.editors.BooleanPropertyEditor
  •  java.lang.Byte -> griffon.core.resources.editors.BytePropertyEditor
  •  java.lang.Short -> griffon.core.resources.editors.ShortPropertyEditor
  •  java.lang.Integer -> griffon.core.resources.editors.IntegerPropertyEditor
  •  java.lang.Long -> griffon.core.resources.editors.LongPropertyEditor
  •  java.lang.Float -> griffon.core.resources.editors.FloatPropertyEditor
  •  java.lang.Double -> griffon.core.resources.editors.DoublePropertyEditor
  •  java.util.Calendar -> griffon.core.resources.editors.CalendarPropertyEditor
  •  java.util.Date -> griffon.core.resources.editors.DatePropertyEditor

Optional Format in @InjectedResource

The @griffon.core.resources.InjectedResource annotation supports an optional format property that can be used as a hint for PropertyEditors when value conversion is performed.

Action Interceptors

Plugin authors now have the chance to define a new type of component: action interceptors. Action interceptors are executed before and after a controller action, thus allowing plugin authors to configure the execution environment. See the Controllers section in the Guide for more information.

Compatibility

The following plugins need to be updated to their latest versions

  • dialogs
  • dialogs-javafx
  • lombok

Sample Applications

Griffon 1.3.0 ships with 8 sample applications of varying levels of complexity demonstrating various parts of the framework. In order of complexity they are:

File Viewer

File Viewer is a simple demonstration of creating new MVCGroups on the fly.

Source: samples/FileViewer

To run the sample from source, change into the source directory and run griffon run-app from the command prompt.

GroovyEdit

GroovyEdit is an improved version of FileViewer that uses custom observable models.

Source: samples/GroovyEdit

To run the sample from source, change into the source directory and run griffon run-app from the command prompt.

Font Picker

Font Picker demonstrates form based data binding to adjust the sample rendering of system fonts.

Source: samples/FontPicker

To run the sample from source, change into the source directory and run griffon run-app from the command prompt.

Greet

Greet, a full featured Griffon Application, is a Twitter client. It shows Joint Java/Groovy compilation, richer MVCGroup interactions, and network service based data delivery.

Source: samples/Greet

To run the sample from source, change into the source directory and run griffon run-webstart from the command prompt. Because Greet uses JNLP APIs for browser integration using run-app will prevent web links from working.

SwingPad

SwingPad, a full featured Griffon Application, is a scripting console for rendering Groovy SwingBuilder views.

Source: samples/SwingPad

To run the sample from source, change into the source directory and run griffon run-app from the command prompt.

GroovyFXPad

GroovyFXPad, a full featured Griffon Application, is a scripting console for rendering GroovyFX views.

Source: samples/GroovyFXPad

To run the sample from source, change into the source directory and run griffon run-app from the command prompt.

FxBrowser

FxBrowser is a trivial JavaFX powered browser that demonstrates Griffon's integration with JavaFX.

Source: samples/FxBrowser

To run the sample from source, change into the source directory and run griffon run-app from the command prompt.

WeatherWidget

WeatherWidget demonstrates binding, threading and plugin usage.

Source: samples/WeatherWidget

To run the sample from source, change into the source directory and run griffon run-app from the command prompt.

Release Notes

1.3.0

JIRA Issues
urlhttp://jira.codehaus.org/sr/jira.issueviews:searchrequest-xml/temp/SearchRequest.xml?fixfor=19049&pid=11833&resolution=1&sorter/field=priority&sorter/order=DESC&sorter/field=issuekey&sorter/order=ASC&tempMax=1000