Creating a New JAR File

You can create a new JAR file in the workbench.

1.

In the Packages view, you can optionally select one or more Java elements to export.

2.

From the menu bar, select File > Export.

3.

Select JAR file, then click Next.

4.

If you did not already do so, select the resources that you want to export in the What do you want to export? field on the JAR Package Specification page.

5.

Choose if you want to

  • Export generated class files and resources and/or
  • Export Java source files and resources

Note: Selected resources are exported in both cases.

6.

In the Where do you want the exported resources to go? field, either type or click Browse to select a location for the JAR file.

7.

Choose to turn the following options on or off:

  • Compress the contents of the JAR file
  • Overwrite existing files without warning (if off, then you will be prompted to confirm the replacement of each file that would be overwritten)

Note: The overwrite option is applied when writing the JAR file, the JAR description, and the manifest file.

8.

Click Finish to create the JAR file immediately.

Or, click Next if you want to use the JAR Packaging Options page to: