Creating the Jar File

Once you have all the necessary classes and the XML descriptor created, you must create a jar file containing this information to represent the generator. While a jar file is basically a zip file containing many other files, you must follow a specific process as defined below, to create a jar file so that its contents are organized in a meaningful fashion.

Organizing the Files

Organize your files in your directory system in a structure corresponding to the following:

  • Any package structure used in your java classes.

  • Any organization of files desired.

The structure must also correspond to the file paths specified in the XML descriptor. The root of the relevant directory structure is considered to be the source directory (sourcedir) in the command below. For example, if your java package name is com.engineous.plugin.doe.generator and the com directory resides at some location in your directory system c:\...\com, the source directory should be c:\...\

Jarring the Files

The jar file requires a manifest file that specifies summary information of the contents of the jar file. Use the following format for the manifest file:

Manifest-Version: 1.0

Name: com/engineous/plugin/doe/generator/DOETechGen.xml
Meta-Model: true

Replace the Created-By value with the author name and replace the Name item with the path to the XML descriptor file for this plug-in generator, starting at the source directory as defined above. Place this manifest file directly at the top level of the source directory.

Type jar at a command prompt to provide usage instructions for the jar command. If the jar command is not found, locate it in your jdk1.6\bin directory and either add it to your PATH environment variable or type the full path to it when using it.

Execute the following command from a command prompt:

jar -cvfm MyNewJar.jar MyManifest.mf -C sourcedir/

Replace the desired jar file name, manifest file name, and sourcedir with the appropriate names.

This procedure will create a jar file MyNewJar.jar with the given manifest and will include all the files in the sourcedir directory and all of its subdirectories.

Publishing the Generator Jar File

To use the generator in the Isight environment, the generator must be published to the Isight Library. It can be published either by using the Isight Library interface or the Command Line Client.

Publishing Using the Library Interface

To publish the component using the Library interface:

Launch the Library interface using one of the following methods:

  • Execute the library file in your <Isight_install_directory>\<operating_system>\code\bin directory.

  • Click Library on the Design Gateway toolbar.

    Click Publish on the Library toolbar to initiate the publishing process.

For more information on using the Isight Library, see Using the Isight Library in the Isight User’s Guide.

Publishing Using the Command Line Client

To publish the component using the Command Line Client, type the following command into a Command Line Interface on one line:

  • Windows: fipercmd.bat publish file:MyNewJar.jar type:metamodel file:

  • Linux: fipercmd publish file:MyNewJar.jar type:metamodel

You can also type fipercmd to start the Command Line Client in interactive mode. You can then issue the publish command directly.

For more information on using the Command Line Client, as well as the different modes available (including interactive mode), see Using the Command Line Client in the Isight User’s Guide.