naming conventions
wtp project naming conventions
WTP LogoWTP Home
  Updated 2004-11-05
Introduction
 

This document summarizes the WTP project naming conventions for plug-ins, packages, and CVS modules.

Plug-ins and Packages
 

One of the main goals of this naming convention is to make it easy to find the component that any class belongs to. This is achieved by adopting the convention of putting the component name in the package or plug-in name, preferably as the fourth component.

 

The Eclipse Platform Naming Conventions state that following org.eclipse, the third component of the package or plug-in name should be the subproject name, which in our case is wst or jst. The fourth component is the component name, e.g. xml or jsp, unless the code is non-API which is signalled by the use of one of the following reserved words:

 
  • internal - code internal to the plug-in, i.e. not part of its API
  • examples - example code
  • tests - test cases
 

If one of the reserved works appears as the fourth part of the name, then the fifth part should be the component name.

 

In the WTP project we are relaxing this convention so that the reserved word may appear after the fourth component. For example, org.eclipse.wst.xml.tests indicates test cases that are used for the xml component of the wst subproject. The prefered usage is to put the reserved names in the fifth position, leaving the fourth position for the component name.

 

Consider the following examples for the server component of the wst subproject:

 
  • org.eclipse.server.ui.internal.debug - OK and the preferred naming
  • org.eclipse.server.internal.ui.debug - OK for compatibility with Eclipse platform guidelines, but not preferred
  • org.eclipse.server.ui.debug.internal - OK but not preferred
  • org.eclipse.ui.debug.internal - WRONG since the component name is missing
CVS Modules
 

The WTP project CVS repository is organized as follows. The top level folder is the subproject name, i.e. wst or jst. The second level contains a components folders. The components folder contains one folder per component, e.g. xml or jsp. Each component folder contains the following folders:

 
  • features - the component features
  • plugins - the comnponent plug-ins
  • tests - the component test suites packaged as plug-ins
 

Any of the features, plugins, and tests folders may be absent if they do not apply to the component.

 

For example, the server component of the wst subproject is organized as follows:

  • wst
    • components
      • server
        • features
        • plugins
        • tests