Difference between revisions of "Creating a new plug-in using eclipse (How to extend Rodin Tutorial)"

From Event-B
Jump to navigationJump to search
imported>Pascal
imported>Pascal
Line 26: Line 26:
 
3. In the field Name, put the name of the plug-in, here Qualitative Probabilistic Reasoning Plug-in,<br>
 
3. In the field Name, put the name of the plug-in, here Qualitative Probabilistic Reasoning Plug-in,<br>
 
4. In the provider field, you can put the name of your company or institution,<br>
 
4. In the provider field, you can put the name of your company or institution,<br>
5. Ensure that the Execution Environment used is Java 1.6 (the one used by the Rodin Platform v.2.0),<br>
+
5. Ensure that the Execution Environment is set to the appropriate Java version (the one used by the current Rodin Platform API),<br>
 
6. Enter the class name of the plug-in activator, preceded by its containing package. The activator is the static class responsible of the plug-in lifecycle (start, stop, etc.).<br>
 
6. Enter the class name of the plug-in activator, preceded by its containing package. The activator is the static class responsible of the plug-in lifecycle (start, stop, etc.).<br>
 
Deselect "This plug-in will make contributions to the UI" as we will contribute to the UI with another dedicated plugin.
 
Deselect "This plug-in will make contributions to the UI" as we will contribute to the UI with another dedicated plugin.

Revision as of 14:18, 20 August 2010

In this part

We will explain how to use Eclipse to easily create a plug-in package structure for our implementation. Developers which are familiar with plug-in building may skip this part and go to the next page of this tutorial. Before starting to perform the following step, you should have your development environment ready and open.

Step 1

To create a plug-in, go to "File > New > Other" and select "Plug-in Project" either from the general list if it appears, or from the category "Plug-in Development". Click on "Next".

Extend Rodin Tuto 1 1 File new plugin.png

Step 2

The following wizard page appears:

Extend Rodin Tuto 1 2 NewPlug-inProject.png

1. In project name, enter the name of the plugin package that must appear in the project hierarchy. We used fr.systerel.rodinextension.sample but the formalism used often corresponds to mydomain.mycompany.mypluginname
2. Verify that the plug-in is targeted to run with the appropriate Eclipse version and click on "Next".

Step 3

Extend Rodin Tuto 1 3 NewPlug-inProject Content.png

1. In field ID, enter the unique id that will identify the plug-in. Generally, we use the project name entered in the previous step : fr.systerel.rodinextension.sample,
2. The version identify, the current plug-in version. This field can be later updated via the MANIFEST file. We let the default value 1.0.0.qualifier,
3. In the field Name, put the name of the plug-in, here Qualitative Probabilistic Reasoning Plug-in,
4. In the provider field, you can put the name of your company or institution,
5. Ensure that the Execution Environment is set to the appropriate Java version (the one used by the current Rodin Platform API),
6. Enter the class name of the plug-in activator, preceded by its containing package. The activator is the static class responsible of the plug-in lifecycle (start, stop, etc.).
Deselect "This plug-in will make contributions to the UI" as we will contribute to the UI with another dedicated plugin. Ensure that Rich Client Application is set to No
7. Click on "Finish"

What we got

Extend Rodin Tuto 1 4 ProjectExplorer1.png

Eclipse created the plug-in structure that we will be able to use to extend Rodin.