Deploying sample appdef files

When a pattern developer deploys a pattern to other users, there is the need to document in some way the appdef file schema required by the pattern. The "industrial strength" solution involves building an Eclipse plugin that defines the plugin and which also provides Eclipse-enabled help to describe the use of that pattern.

A more informal mechanism is available to help pattern users. The pattern developer can declare one or more files within the pattern to be sample appdefs. A new resource wizard in the "Design Pattern Toolkit" category can then create a new file in a project with the same contents as a selected sample appdef from a pattern.

To declare a file to be a sample appdef file, the pattern developer edits the .pattern file in the root directory of the pattern project. By default, there will be four lines in the .pattern file already: "SetName", "SetID", "ControllerID" and "Version". To declare a sample appdef, add another line to the .pattern file in the form:


Appdef: name="sample.appdef" description="Basic aardvaark"

The name attribute is the name of the file relative to the project root and the description attribute is the text displayed (along with "SetName", the pattern name) in the new resource wizard. You may declare as many sample appdefs as you need.


© Copyright IBM Corporation 2000, 2005. All Rights Reserved.