Contents Previous

Packaging Your Source Code Control Extension

This section outlines how to package your finished source code control extension as a JAR file that JDeveloper automatically loads on startup. This involves:

After you have created the JAR file, you can store it in your %JDEV_HOME%/jdev/lib/ext directory to install your source code control client into JDeveloper. Using an 'autoloading' JAR file means you and your users do not have to modify any configuration files for the JDeveloper IDE to install the extension.

Note: For full details on how to package your source code control extension, see the JDeveloper online help.

Writing a Manifest File

A manifest file is an XML file that describes how your extension integrates into the JDeveloper IDE. You must include a manifest file in your JAR file to describe how the extension in that JAR should be installed into JDeveloper.

Note: We assume you want to package your extension using JDeveloper. If not, you can also create the JAR file from the command line. For more details on the format of a manifest file, see the %JDEV_HOME%/jdev/lib/ext/readme.txt file.

To create your manifest file in the JDeveloper IDE:

  1. Select your project, then choose File | Open... .
  2. Make sure the current directory in the File Open dialog is the root directory of your source path, e.g. if your source path is c:\jdev\myprojects\project1\src, you must be in c:\jdev\myprojects\project1\src.
  3. Click the New Folder toolbar button, and create a folder called META-INF. Open META-INF.
  4. Enter jdev-ext.xml in the File name field and click OK.
  5. Enter the following in the code editor (replace org.acme.scm.ACMEVCSClient and Acme Source Control with the class name and display name of your source code control system respectively). When you have finished, save and close the file:
<?xml version = '1.0' encoding = 'windows-1252'?>
<extensions xmlns=""> <feature> <group name="Acme Source Control"> <description>Acme VCS extension</description> <extension> <addin>org.acme.scm.ACMEVCSClient</addin> <dependency_addin>oracle.ideimpl.scm.VersionManager</dependency_addin> </extension> </group> </feature> </extensions>

Creating a Deployment Profile

To create a JAR file in JDeveloper, you must use a deployment profile. To create a deployment profile in JDeveloper:

  1. Select your project, then choose File | New... .
  2. Select JAR File - Simple Archive, under General | Deployment Profiles.
  3. Enter a suitable filename for the deployment profile.
  4. Accept the default options in the JAR Deployment Profile Settings dialog.
  5. Choose File | Save to save the profile.

Deploying a JAR File to JDeveloper

To deploy your JAR file to JDeveloper:

  1. Select the deployment profile created above and right click on it.
  2. Choose Deploy to JAR File. You will find your deployed JAR file in the deploy directory under your project directory (assuming you used the default options in step 4 of Creating a Deployment Profile above).
  3. Copy the deployed JAR file to %JDEV_HOME%/jdev/lib/ext then restart JDeveloper.
  4. After JDeveloper restarts, you should see your extension in the IDE. Check the extension was successfully installed using Tools | Preferences.... Select the Extension Manager node. Your extension should display under System Extensions.

Troubleshooting Any Possible Errors

If your source code control extension does not appear to work correctly:

Share your Work

If you believe your extension will benefit the wider community of JDeveloper users, we encourage you to make it available to them using OTN. For more details, see the OTN Extensions Exchange.

Contents Previous