Jump to: navigation, search

Difference between revisions of "MoDisco/DeveloperGuide"

(Add example naming)
Line 1: Line 1:
<css>p{margin-top:0.7em;margin-bottom:0.5em;}</css>
+
<css>p{margin-top:0.7em;margin-bottom:0.5em;}</css>  
=Plug-ins naming=
+
 
==Infrastructure plug-ins naming==
+
= Plug-ins naming =
 +
 
 +
== Infrastructure plug-ins naming ==
 +
 
 
For common components:  
 
For common components:  
* a plug-in org.eclipse.gmt.modisco.infra.common.core
+
 
** contains non-graphical components
+
*a plug-in org.eclipse.gmt.modisco.infra.common.core  
* a plug-in org.eclipse.gmt.modisco.infra.common.ui (if necessary)
+
**contains non-graphical components  
** if necessary, contains graphical components (except editor features)
+
*a plug-in org.eclipse.gmt.modisco.infra.common.ui (if necessary)  
 +
**if necessary, contains graphical components (except editor features)
 +
 
 
For each infrastructure component named x (except OMG standards implementation):  
 
For each infrastructure component named x (except OMG standards implementation):  
* a plug-in org.eclipse.gmt.modisco.infra.x
 
** contains the meta-model implementation of the component x (if necessary)
 
* a plug-in org.eclipse.gmt.modisco.infra.x.core
 
** contains non-graphical components
 
* a plug-in org.eclipse.gmt.modisco.infra.x.editor
 
** if necessary, contains the component allowing to execute the Eclipse’s edit action.
 
* a plug-in org.eclipse.gmt.modisco.infra.x.ui (if necessary)
 
** if necessary, contains the graphical components.
 
For each subcomponent y of the infrastructure’s component x
 
* a plug-in org.eclipse.gmt.modisco.infra.x.y
 
* a plug-in org.eclipse.gmt.modisco.infra.x.y.core
 
* a plug-in org.eclipse.gmt.modisco.infra.x.y.editor
 
* a plug-in org.eclipse.gmt.modisco.infra.x.y.ui (if necessary)
 
  
==Technology plug-ins naming==
+
*a plug-in org.eclipse.gmt.modisco.infra.x  
For each component dedicated to the technology x :
+
**contains the meta-model implementation of the component x (if necessary)
* a plug-in org.eclipse.gmt.modisco.x : contains the meta-model implementation
+
*a plug-in org.eclipse.gmt.modisco.infra.x.core
* a plug-in org.eclipse.gmt.modisco.x.discoverer : contains the basic discoverers
+
**contains non-graphical components
* a plug-in org.eclipse.gmt.modisco.x.discoverer.y : for each additional discoverer
+
*a plug-in org.eclipse.gmt.modisco.infra.x.editor  
* a plug-in org.eclipse.gmt.modisco.x.edit : EMF edit classes
+
**if necessary, contains the component allowing to execute the Eclipse’s edit action.  
* a plug-in org.eclipse.gmt.modisco.x.editor : EMF editor classes and reflexive editor customization
+
*a plug-in org.eclipse.gmt.modisco.infra.x.ui (if necessary)
* a plug-in org.eclipse.gmt.modisco.x.custom : UICustom + facet + queries
+
**if necessary, contains the graphical components.
* a plug-in org.eclipse.gmt.modisco.x.zconverter : converter from x to z
+
==Use-cases plug-ins naming==
+
For each component dedicated to a use-case x:
+
* a plug-in org.eclipse.gmt.modisco.usecase.x
+
  
==For each component==
+
For each subcomponent y of the infrastructure’s component x  
For each component or sub-component x :
+
* a plug-in x.doc referred by the parent component
+
* a plug-in x.tests
+
* a plug-in x.examples.y
+
** "y" is the example name if it exists more than one example for the component "x".
+
  
=Feature naming=
+
*a plug-in org.eclipse.gmt.modisco.infra.x.y
* The feature name suffixed by ".feature"
+
*a plug-in org.eclipse.gmt.modisco.infra.x.y.core
* Feature id: not suffixed by ".feature" (can have the same name as a plug-in)
+
*a plug-in org.eclipse.gmt.modisco.infra.x.y.editor
 +
*a plug-in org.eclipse.gmt.modisco.infra.x.y.ui (if necessary)
  
=Package naming=
+
== Technology plug-ins naming ==
* Prefixed by the name of the plug-in containing the package
+
* The EMF generation parameters must be changed to conform to this rule
+
  
=Coding conventions=
+
For each component dedicated to the technology x&nbsp;:
[[MoDisco/CodingConventions|Coding conventions]]
+
  
=APIs visibility=
+
*a plug-in org.eclipse.gmt.modisco.x&nbsp;: contains the meta-model implementation
see [[MoDisco/API_Policy|MoDisco API Visibility]]
+
*a plug-in org.eclipse.gmt.modisco.x.discoverer&nbsp;: contains the basic discoverers
 +
*a plug-in org.eclipse.gmt.modisco.x.discoverer.y&nbsp;: for each additional discoverer
 +
*a plug-in org.eclipse.gmt.modisco.x.edit&nbsp;: EMF edit classes
 +
*a plug-in org.eclipse.gmt.modisco.x.editor&nbsp;: EMF editor classes and reflexive editor customization
 +
*a plug-in org.eclipse.gmt.modisco.x.custom&nbsp;: UICustom + facet + queries
 +
*a plug-in org.eclipse.gmt.modisco.x.zconverter&nbsp;: converter from x to z
  
The Eclipse API Tools must be activated on each MoDisco project, with an API baseline set to a folder containing the MoDisco plug-ins from the previous release.
+
== Use-cases plug-ins naming ==
This is to ensure that no unintentional API breakage happens from release to release.
+
  
The following article explains how to use the API Tools:<br>
+
For each component dedicated to a use-case x:  
[https://www.ibm.com/developerworks/opensource/library/os-eclipse-api-tools/ https://www.ibm.com/developerworks/opensource/library/os-eclipse-api-tools/]
+
  
=Java Compliance Level=
+
*a plug-in org.eclipse.gmt.modisco.usecase.x
Java 5 compliance level is required. Take care of:
+
* checking compilation, at least once, with Java 5 compiler compliance level and using a JRE5 library
+
* indicating on plugin Manifest "Bundle-RequiredExecutionEnvironment: J2SE-1.5"
+
  
=== SuppressWarnings("rawtypes") ===
+
== For each component ==
Eclipse 3.6 M3 introduced a change in the way it handles "@SuppressWarnings" for generic types that are used without specifying the type parameter.
+
  
Previously, <code>@SuppressWarnings("unchecked")</code> was used to suppress the corresponding warning. Now, Eclipse expects <code>@SuppressWarnings("rawtypes")</code> instead (see [https://bugs.eclipse.org/bugs/show_bug.cgi?id=290034 bug 290034]).
+
For each component or sub-component x&nbsp;:  
  
Problem is, this doesn't seem to be supported in other Java compilers (like the Sun or IBM Java compilers). It will eventually be, but not until Java 7, from what I could gather.
+
*a plug-in x.doc referred by the parent component
 +
*a plug-in x.tests
 +
*a plug-in x.examples.y
 +
**"y" is the example name if it exists more than one example for the component "x".
  
The MoDisco build uses an IBM compiler which is installed on the build machine, and which emits warnings whenever it encounters this <code>@SuppressWarnings("rawtypes")</code> it doesn't understand.
+
= Feature naming =
 +
 
 +
*The feature name suffixed by ".feature"
 +
*Feature id: not suffixed by ".feature" (can have the same name as a plug-in)
 +
 
 +
= Package naming =
 +
 
 +
*Prefixed by the name of the plug-in containing the package
 +
*The EMF generation parameters must be changed to conform to this rule
 +
 
 +
= Coding conventions =
 +
 
 +
[[MoDisco/CodingConventions|Coding conventions]]
 +
 
 +
= APIs visibility =
 +
 
 +
see [[MoDisco/API Policy|MoDisco API Visibility]]
 +
 
 +
The Eclipse API Tools must be activated on each MoDisco project, with an API baseline set to a folder containing the MoDisco plug-ins from the previous release. This is to ensure that no unintentional API breakage happens from release to release.
 +
 
 +
The following article explains how to use the API Tools:<br> [https://www.ibm.com/developerworks/opensource/library/os-eclipse-api-tools/ https://www.ibm.com/developerworks/opensource/library/os-eclipse-api-tools/]
 +
 
 +
= Java Compliance Level =
 +
 
 +
Java 5 compliance level is required. Take care of:
 +
 
 +
*checking compilation, at least once, with Java 5 compiler compliance level and using a JRE5 library
 +
*indicating on plugin Manifest "Bundle-RequiredExecutionEnvironment: J2SE-1.5"
 +
 
 +
=== SuppressWarnings("rawtypes")  ===
 +
 
 +
Eclipse 3.6 M3 introduced a change in the way it handles "@SuppressWarnings" for generic types that are used without specifying the type parameter.
 +
 
 +
Previously, <code>@SuppressWarnings("unchecked")</code> was used to suppress the corresponding warning. Now, Eclipse expects <code>@SuppressWarnings("rawtypes")</code> instead (see [https://bugs.eclipse.org/bugs/show_bug.cgi?id=290034 bug 290034]).
 +
 
 +
Problem is, this doesn't seem to be supported in other Java compilers (like the Sun or IBM Java compilers). It will eventually be, but not until Java 7, from what I could gather.
 +
 
 +
The MoDisco build uses an IBM compiler which is installed on the build machine, and which emits warnings whenever it encounters this <code>@SuppressWarnings("rawtypes")</code> it doesn't understand.  
 +
 
 +
A solution to keep both Eclipse and the build happy is to tell Eclipse to keep its old behavior, by adding the following line in the VM arguments in eclipse.ini:
  
A solution to keep both Eclipse and the build happy is to tell Eclipse to keep its old behavior, by adding the following line in the VM arguments in eclipse.ini:
 
 
  -DsuppressRawWhenUnchecked=true
 
  -DsuppressRawWhenUnchecked=true
  
And continue using <code>@SuppressWarnings("unchecked")</code>.
+
And continue using <code>@SuppressWarnings("unchecked")</code>.  
  
[[Category:MoDisco]]
+
= Versioning =
  
=Versioning=
+
All plug-ins must have the same version as the project version (current = 0.7.1, next = 0.8.0)
  
All plug-ins must have the same version as the project version (current = 0.7.1, next = 0.8.0)
+
= Testing =
  
=Testing=
+
To install SWTBot the following update site must be used: http://download.eclipse.org/technology/swtbot/helios/dev-build/update-site
  
To install SWTBot the following update site must be used: http://download.eclipse.org/technology/swtbot/helios/dev-build/update-site
+
= MoDisco Wiki =
 +
 
 +
== Help Content ==
 +
 
 +
MoDisco help content for Eclipse IDE is generated with the [[Mylyn|Mylyn]] Project directly from the MoDisco Wiki.
 +
 
 +
== Template ==
 +
 
 +
MediaWiki Template are used to organize MoDisco Components in several tabs.  
 +
 
 +
{{MoDiscoTabs|KDM|
 +
{{MoDiscoTab|KDM|Documentation|0.7}}{{MoDiscoTab|KDM|Documentation|0.8}}{{MoDiscoTab|KDM|Documentation|0.9}}
 +
}}
 +
 
 +
[[Category:MoDisco]]

Revision as of 05:07, 7 September 2010


Plug-ins naming

Infrastructure plug-ins naming

For common components:

  • a plug-in org.eclipse.gmt.modisco.infra.common.core
    • contains non-graphical components
  • a plug-in org.eclipse.gmt.modisco.infra.common.ui (if necessary)
    • if necessary, contains graphical components (except editor features)

For each infrastructure component named x (except OMG standards implementation):

  • a plug-in org.eclipse.gmt.modisco.infra.x
    • contains the meta-model implementation of the component x (if necessary)
  • a plug-in org.eclipse.gmt.modisco.infra.x.core
    • contains non-graphical components
  • a plug-in org.eclipse.gmt.modisco.infra.x.editor
    • if necessary, contains the component allowing to execute the Eclipse’s edit action.
  • a plug-in org.eclipse.gmt.modisco.infra.x.ui (if necessary)
    • if necessary, contains the graphical components.

For each subcomponent y of the infrastructure’s component x

  • a plug-in org.eclipse.gmt.modisco.infra.x.y
  • a plug-in org.eclipse.gmt.modisco.infra.x.y.core
  • a plug-in org.eclipse.gmt.modisco.infra.x.y.editor
  • a plug-in org.eclipse.gmt.modisco.infra.x.y.ui (if necessary)

Technology plug-ins naming

For each component dedicated to the technology x :

  • a plug-in org.eclipse.gmt.modisco.x : contains the meta-model implementation
  • a plug-in org.eclipse.gmt.modisco.x.discoverer : contains the basic discoverers
  • a plug-in org.eclipse.gmt.modisco.x.discoverer.y : for each additional discoverer
  • a plug-in org.eclipse.gmt.modisco.x.edit : EMF edit classes
  • a plug-in org.eclipse.gmt.modisco.x.editor : EMF editor classes and reflexive editor customization
  • a plug-in org.eclipse.gmt.modisco.x.custom : UICustom + facet + queries
  • a plug-in org.eclipse.gmt.modisco.x.zconverter : converter from x to z

Use-cases plug-ins naming

For each component dedicated to a use-case x:

  • a plug-in org.eclipse.gmt.modisco.usecase.x

For each component

For each component or sub-component x :

  • a plug-in x.doc referred by the parent component
  • a plug-in x.tests
  • a plug-in x.examples.y
    • "y" is the example name if it exists more than one example for the component "x".

Feature naming

  • The feature name suffixed by ".feature"
  • Feature id: not suffixed by ".feature" (can have the same name as a plug-in)

Package naming

  • Prefixed by the name of the plug-in containing the package
  • The EMF generation parameters must be changed to conform to this rule

Coding conventions

Coding conventions

APIs visibility

see MoDisco API Visibility

The Eclipse API Tools must be activated on each MoDisco project, with an API baseline set to a folder containing the MoDisco plug-ins from the previous release. This is to ensure that no unintentional API breakage happens from release to release.

The following article explains how to use the API Tools:
https://www.ibm.com/developerworks/opensource/library/os-eclipse-api-tools/

Java Compliance Level

Java 5 compliance level is required. Take care of:

  • checking compilation, at least once, with Java 5 compiler compliance level and using a JRE5 library
  • indicating on plugin Manifest "Bundle-RequiredExecutionEnvironment: J2SE-1.5"

SuppressWarnings("rawtypes")

Eclipse 3.6 M3 introduced a change in the way it handles "@SuppressWarnings" for generic types that are used without specifying the type parameter.

Previously, @SuppressWarnings("unchecked") was used to suppress the corresponding warning. Now, Eclipse expects @SuppressWarnings("rawtypes") instead (see bug 290034).

Problem is, this doesn't seem to be supported in other Java compilers (like the Sun or IBM Java compilers). It will eventually be, but not until Java 7, from what I could gather.

The MoDisco build uses an IBM compiler which is installed on the build machine, and which emits warnings whenever it encounters this @SuppressWarnings("rawtypes") it doesn't understand.

A solution to keep both Eclipse and the build happy is to tell Eclipse to keep its old behavior, by adding the following line in the VM arguments in eclipse.ini:

-DsuppressRawWhenUnchecked=true

And continue using @SuppressWarnings("unchecked").

Versioning

All plug-ins must have the same version as the project version (current = 0.7.1, next = 0.8.0)

Testing

To install SWTBot the following update site must be used: http://download.eclipse.org/technology/swtbot/helios/dev-build/update-site

MoDisco Wiki

Help Content

MoDisco help content for Eclipse IDE is generated with the Mylyn Project directly from the MoDisco Wiki.

Template

MediaWiki Template are used to organize MoDisco Components in several tabs.


MoDisco
Website
Download
Community
Mailing ListForums
Bugzilla
Open
Help Wanted
Bug Day
Contribute
Browse SourceProject Set File