FeaturesPluginsDocs & SupportCommunityPartners

API Support UI [5.0u1]

Version:
February 6, 2006
Author:
Jesse Glick
Abstract:

Proposal and record of the UI of API Support (NBM project development) as of the 5.0 Update 1 release. For other versions and general background please see the UI Overview.

NetBeans Platform Manager—Dialog UI

There should be a menu item Tools | NetBeans Platform Manager, somewhat analogous to the existing Java Platform Manager, which would open a (modal?) dialog:

NetBeans Platform Manager Dialog—Modules Tab Selected

+-------------------------------------------------------------------------------+
| NetBeans Platform Manager                                                   X |
+-------------------------------------------------------------------------------+
| _P_latforms:                                                                  |
| +-------------------------------+                                             |
| | NetBeans IDE Dev 050429 (Defa | Platform _N_ame:   NetBeans Platform 5.0    |
| |[NetBeans Platform 5.0]        | Platform _F_older: /opt/nbp50               |
| | NetBeans Platform Dev 050429  |                                             |
| |                               | /-----------/---------/---------/---------| |
| |                               | | [Modules] | Sources | Javadoc | Harness | |
| |                               | +-----------------------------------------| |
| |                               | | Platform _M_odules:                     | |
| |                               | | +-------------------------------------+ | |
| |                               | | | Auto Update                        ^| | |
| |                               | | | Bootstrap                          .| | |
| |                               | | | Core Implementation                .| | |
| |                               | | | Core - Multi-view Windows          .| | |
| |                               | | | Core - UI                          .| | |
| |                               | | | Core - Windows                     .| | |
| |                               | | | JavaHelp Integration               .| | |
| |                               | | | Loaders API                        .| | |
| |                               | | | Open APIs                          v| | |
| |                               | | +-------------------------------------+ | |
| +-------------------------------+ +-----------------------------------------+ |
| [_A_dd Platform...] [_R_emove]                                                |
|                                                            [[Close]] [_H_elp] |
+-------------------------------------------------------------------------------+

The default platform is always present and cannot be removed. You can add other platforms. The right side of the dialog applies to the platform selected from the list on the left.

Platform Name gives the display label for the platform. The default platform is shown with the suffix (Default). Read-only text field.

Platform Folder shows the installation folder of the platform. Read-only text field.

The Modules tab displays a read-only list of the binary modules detected in the platform, as an alphabetized list of localized module display names.

NetBeans Platform Manager Dialog—Sources Tab Selected

+----------------------------------------------------------------------------+
| NetBeans Platform Manager                                                X |
+----------------------------------------------------------------------------+
| _P_latforms:                                                               |
| +------------------------+                                                 |
| | NetBeans IDE Dev 05042 | Platform _N_ame:   NetBeans Platform 5.0        |
| |[NetBeans Platform 5.0] | Platform _F_older: /opt/nbp50                   |
| | NetBeans Platform Dev  |                                                 |
| |                        | /---------/-----------/---------/---------|     |
| |                        | | Modules | [Sources] | Javadoc | Harness |     |
| |                        | +---------------------------------------------+ |
| |                        | | Platform _S_ources:                         | |
| |                        | | +-----------------------+                   | |
| |                        | | | /src/nb_all           | [Add _F_older...] | |
| |                        | | |                       |                   | |
| |                        | | |                       | [Re_m_ove       ] | |
| |                        | | |                       |                   | |
| |                        | | |                       | [Move _U_p      ] | |
| |                        | | |                       | [Move _D_own    ] | |
| |                        | | |                       |                   | |
| |                        | | |                       |                   | |
| |                        | | |                       |                   | |
| |                        | | +-----------------------+                   | |
| +------------------------+ +---------------------------------------------+ |
| [_A_dd Platform...] [_R_emove]                                             |
|                                                         [[Close]] [_H_elp] |
+----------------------------------------------------------------------------+

The Sources tab lets you add folders containing sources to associate with the binaries. Each folder should be the root of either a netbeans.org CVS checkout, or a module suite.

NetBeans Platform Manager Dialog—Javadoc Tab Selected

+----------------------------------------------------------------------------+
| NetBeans Platform Manager                                                X |
+----------------------------------------------------------------------------+
| _P_latforms:                                                               |
| +------------------------+                                                 |
| | NetBeans IDE Dev 05042 | Platform _N_ame:  NetBeans Platform 5.0         |
| |[NetBeans Platform 5.0] | Platform _Folder: /opt/nbp50                    |
| | NetBeans Platform Dev  |                                                 |
| |                        | /---------/---------/-----------/---------|     |
| |                        | | Modules | Sources | [Javadoc] | Harness |     |
| |                        | +---------------------------------------------+ |
| |                        | | Platform _J_avadoc:                         | |
| |                        | | +-------------------+                       | |
| |                        | | | /opt/nb50jdoc.zip | [Add _Z_IP/Folder...] | |
| |                        | | |                   |                       | |
| |                        | | |                   | [Re_m_ove           ] | |
| |                        | | |                   |                       | |
| |                        | | |                   | [Move _U_p          ] | |
| |                        | | |                   | [Move _D_own        ] | |
| |                        | | |                   |                       | |
| |                        | | |                   |                       | |
| |                        | | |                   |                       | |
| |                        | | +-------------------+                       | |
| +------------------------+ +---------------------------------------------+ |
| [_A_dd Platform...] [_R_emove]                                             |
|                                                         [[Close]] [_H_elp] |
+----------------------------------------------------------------------------+

The Javadoc tab lets you add ZIP files or folders containing Javadoc to associate with the binaries. Each entry must use the file layout recognized by apisupport (for which see harness/README).

NetBeans Platform Manager Dialog—Harness Tab Selected

+---------------------------------------------------------------------------------------+
| NetBeans Platform Manager                                                           X |
+---------------------------------------------------------------------------------------+
| _P_latforms:                                                                          |
| +------------------------+                                                            |
| | NetBeans IDE Dev 05042 | Platform _N_ame:  NetBeans Platform 5.0                    |
| |[NetBeans Platform 5.0] | Platform _Folder: /opt/nbp50                               |
| | NetBeans Platform Dev  |                                                            |
| |                        | /---------/---------/---------/-----------|                |
| |                        | | Modules | Sources | Javadoc | [Harness] |                |
| |                        | +--------------------------------------------------------+ |
| |                        | | (*) Harness supplied with _I_DE                        | |
| |                        | | ( ) Harness supplied with _P_latform                   | |
| |                        | | ( ) _O_ther: [_________________________] [_B_rowse...] | |
| |                        | |                                                        | |
| |                        | | Selected Harness _V_ersion: [5.0 update 1____________] | |
| |                        | |                                                        | |
| |                        | |                                                        | |
| |                        | |                                                        | |
| |                        | |                                                        | |
| |                        | |                                                        | |
| |                        | |                                                        | |
| |                        | |                                                        | |
| +------------------------+ +--------------------------------------------------------+ |
| [_A_dd Platform...] [_R_emove]                                                        |
|                                                                    [[Close]] [_H_elp] |
+---------------------------------------------------------------------------------------+

The Harness tab lets you select a build harness to use independently of the actual modules in the platform. For example, using the 5.0u1 harness with a 5.0 platform you can select a specific JDK to build and run against, even though the harness bundled with 5.0 did not permit this.

Harness supplied with IDE, if selected, uses the harness bundled with the NetBeans IDE that is running. This will generally be the most up-to-date harness available and so is recommended. Always selected for the default platform.

Harness supplied with Platform, if selected, uses the harness which is bundled with this platform (currently in the harness cluster subdirectory). Disabled for the default platform.

Other lets you use any harness on disk. Browse… lets you pick the harness directory using a file chooser. Disabled for the default platform.

Selected Harness Version (read-only) displays a version identification of the currently selected harness. Currently possible values are 5.0, 5.0 update 1, and unknown.

Old Harness Upgrade Dialog

When in 5.0u1 the user first opens the NetBeans Platform Manager dialog, if there are some registered custom (non-default) platforms which are still using a 5.0-version build harness associated with that (5.0) platform, a dialog appears:

Upgrade 5.0 Build Harnesses

You have some custom NetBeans platforms which are still set to use the 5.0 version of the module build harness. While this version still works, you will be missing some functionality and fixes in the newer harness. Do you wish to upgrade to the new harness for these platforms? (You can always specify a harness in NetBeans Platform Manager.) (Upgrade | Skip)

NetBeans Platform Manager—Add Platform Subdialog

Add Platform… launches a wizard to register a NB platform in the manager so it will appear in the list. The dialog is named Add NetBeans Platform.

NetBeans Platform Manager—Add Platform Subdialog—Choose Platform Folder

...............................................................................
. Choose Platform Folder                                                      .
. --------------------------------------------------------------------------- .
. Look _In: [[F] opt__________________________________________v] [buttons...] .
. +---------------------------------------------------+                       .
. | nb50                                              | _P_latform Name:      .
. | nb50jdoc.zip                                      | NetBeans Platform 5.0 .
. |[nbp50]                                            |                       .
. |                                                   |                       .
. |                                                   |                       .
. |                                                   |                       .
. |                                                   |                       .
. |                                                   |                       .
. |                                                   |                       .
. |                                                   |                       .
. |                                                   |                       .
. |                                                   |                       .
. |                                                   |                       .
. |                                                   |                       .
. +---------------------------------------------------+                       .
.                                                                             .
. File _N_ame:     [nbp50___________________________________________________] .
. Files of _T_ype: [Platform Folder________________________________________v] .
...............................................................................
                                 _B_ack [[Next>]]  _F_inish   [Cancel] [_H_elp]

Specify the location of the NetBeans platform installation (this will become the netbeans.dest.dir property). Should be an embedded JFileChooser. Enable Finish only in case a valid platform is selected—e.g. check for the existence of a file platform*/core/core.jar.

Should also display a read-only text field giving the computed display name of the platform (blank if no valid platform is currently selected), to assist the user in selecting among different alternatives. The display name is computed from core.jar and should match the value of Product Version in the target platform’s About dialog.

NetBeans Platform Manager—Add Platform Subdialog—Platform Name

...............................................................................
. Platform Name                                                               .
. --------------------------------------------------------------------------- .
. _P_latform Name: [NetBeans Platform 5.0___________________________________] .
.                                                                             .
.                                                                             .
.                                                                             .
.                                                                             .
.                                                                             .
.                                                                             .
.                                                                             .
.                                                                             .
.                                                                             .
.                                                                             .
.                                                                             .
.                                                                             .
.                                                                             .
.                                                                             .
.                                                                             .
.                                                                             .
.                                                                             .
.                                                                             .
.                                                                             .
...............................................................................
                                [_B_ack]  Next>  [[_F_inish]] [Cancel] [_H_elp]

Pick a name for the new platform. Default value should be taken from the computed display name in the previous panel.

Internally, a variant of the name without spaces or other special characters is used as the ID of the platform, for use in Ant property names. For example, the platform called by the user NetBeans Platform 5.0 might be represented in $userdir/build.properties as follows:

nbplatform.NetBeans_Platform_5.0.label=NetBeans Platform 5.0
nbplatform.NetBeans_Platform_5.0.netbeans.dest.dir=/opt/nbp50
# etc.

New Module Project—Wizard UI

User can select File | New Project and choose NetBeans Plug-in Modules as the category and Module Project as the template.

New Module Project Wizard—Name and Location

...............................................................................
. Name and Location                                                           .
. --------------------------------------------------------------------------- .
. Project _N_ame:      [module1_______________________________]               .
. Project _L_ocation:  [/src/mods_____________________________] [Br_o_wse...] .
. Project Fol_d_er:    /src/mods/module1                                      .
. --------------------------------------------------------------------------- .
. (*) S_t_andalone Module                                                     .
.     NetBeans _P_latform:        [NetBeans Platform 5.0______] [_M_anage...] .
.                                                                             .
. ( ) _A_dd to Module Suite                                                   .
.     Module _S_uite:             [Demo App__________________v] [Bro_w_se...] .
.                                                                             .
.                                                                             .
. [X] Set as _M_ain Project                                                   .
...............................................................................
                              [_B_ack] [[Next>]]   _F_inish   [Cancel] [_H_elp]
  

Project Name should be the basename of the folder in which to create the project. May autoincrement module1, module2, etc.

Project Location should be the parent folder in which the project folder will be created. It should default to the last location used, if any. However, if Add to Module Suite is selected, then Project Location should default to the project directory of the selected Module Suite, and should track changes in that combo box until explicitly edited. Browse… opens a directory chooser.

Project Folder displays the concatenation of Project Location and Project Name at any given time.

Standalone Module and Add to Module Suite are radio buttons in a group. Add to Module Suite is selected by default if there are any entries in Module Suite; else Standalone Module is selected. (If Project Folder is a first-, second-, or third-level subdirectory of a netbeans.org CVS checkout, these radio buttons are both unselected and disabled, since they apply only to external modules.)

If Standalone Module is selected, then NetBeans Platform (a noneditable combo box) will be enabled. It lists registered platforms. The default value is the default platform, as in the NetBeans Platform Manager.

If Add to Module Suite is selected, then Module Suite (a noneditable combo box) will be enabled. It lists module suite projects which are currently open in the IDE and also suites of all currently open modules which are contained within a suite, in alphabetical order (of their display names). The default selection, if there is more than one such suite, is the main project, if that is among the choices. Browse… opens a regular project chooser (similar to Open Project) that lets you pick a module suite project on disk, which will be added to the list and selected.

Set as Main Project has its usual meaning.

Error conditions include:

  • Project Location does not yet exist.

  • Project Folder already exists.

  • Add to Module Suite is selected but there is no suite selected in Module Suite.

New Module Project Wizard—Basic Module Properties

...............................................................................
. Basic Module Properties                                                     .
. --------------------------------------------------------------------------- .
. Code _N_ame Base:               [org.yourorghere.module1__________________] .
. Module _D_isplay Name:          [module1]                                   .
.                                                                             .
. _L_ocalizing Bundle:            [org/yourorghere/module1/Bundle.properties] .
. _X_ML Layer:                    [org/yourorghere/module1/layer.xml________] .
.                                                                             .
.                                                                             .
.                                                                             .
.                                                                             .
.                                                                             .
.                                                                             .
.                                                                             .
...............................................................................
                              [_B_ack]   Next>   [[_F_inish]] [Cancel] [_H_elp]
  

Code Name Base must be a valid module code name base; restrictions are identical to those in place on Java package names. Initial value: org.yourorghere. plus Project Name from previous panel (normalized if necessary to exclude unsafe characters, and converted to all lower case).

Module Display Name can be any (nonempty) text. Default Project Name from previous panel.

Localizing Bundle must be a relative path. Default is Code Name Base with . replaced by / plus /Bundle.properties. (Default tracks changes in Code Name Base unless and until this field is edited.)

XML Layer must be a relative path. Default is Code Name Base with . replaced by / plus /layer.xml. (Default tracks changes in Code Name Base unless and until this field is edited.)

Error conditions include:

  • Code Name Base is not a Java package name.

  • Some other module in the module universe is already using that code name base.

  • Localizing Bundle is blank, or does not include a slash (the default package is not permitted for modules), or is not a well-formed relative file path (details TBD), or does not end with .properties.

  • XML Layer is blank, or does not include a slash, or is not a well-formed relative file path (details TBD), or does not end with .xml.

Library Wrapper Module Project—Wizard UI

Invoked as File | New Project… and selecting category NetBeans Plug-in Modules and template Library Wrapper Module Project. HTML description:

Creates a new NetBeans module which is just a wrapper for an existing JAR library. Other modules in the same suite can declare a dependency on the wrapper module to get shared access to library classes.

Library Wrapper Module Project Wizard—Select Library

...............................................................................
. Select Library                                                              .
. --------------------------------------------------------------------------- .
.                                                                             .
. _L_ibrary: [/usr/java/commons-logging-1.0.4.jar_____________] [Br_o_wse...] .
.                                                                             .
. Li_c_ense: [/usr/doc/apache/LICENSE_________________________] [Bro_w_se...] .
.                                                                             .
.                                                                             .
.                                                                             .
.                                                                             .
.                                                                             .
.                                                                             .
.                                                                             .
.                                                                             .
...............................................................................
                              [_B_ack] [[Next>]]   _F_inish   [Cancel] [_H_elp]

Library holds the path to a JAR file which the user can select with Browse… (filter: *.jar,*.zip). Multiple JARs may also be selected.

License can be given a path to a text or (X)HTML file with Browse…, or left blank.

Error conditions include:

  • Library is empty, or does not point to a valid JAR file. (In the case of multiple JARs, any of them is not a valid JAR file.)

  • License is not blank, yet does not point to an existing file.

Warning conditions include:

  • The JAR file referred to by Library contains resources in the default package, which will not be loadable inside NetBeans.

Library Wrapper Module Project Wizard—Name and Location

...............................................................................
. Name and Location                                                           .
. --------------------------------------------------------------------------- .
. Project _N_ame:      [commons-logging_______________________]               .
. Project _L_ocation:  [/src/mods_____________________________] [Br_o_wse...] .
. Project Fol_d_er:    /src/mods/commons-logging                              .
. --------------------------------------------------------------------------- .
.                                                                             .
. Add to Module _S_uite: [Demo App___________________________v] [Bro_w_se...] .
.                                                                             .
.                                                                             .
.                                                                             .
.                                                                             .
.                                                                             .
...............................................................................
                              [_B_ack] [[Next>]]   _F_inish   [Cancel] [_H_elp]

Project Name is a text field. Initial value: the basename of the (first) JAR selected in the previous panel, minus any suffix matching the regexp [0-9._-]+$ (i.e. version numbers in the usual format).

Project Location is a text field with a directory choosable using Browse…; initial value: project directory of the selected module suite, if any.

Project Folder is a read-only text field showing the concatenation of Project Location and Project Name.

Add to Module Suite is a combo box showing open module suite projects; you can choose a different one using Browse… (a project chooser).

Error conditions include:

  • Project Name is blank.

  • Project Location does not yet exist.

  • Add to Module Suite has no selection (i.e. was initially empty), or user tries to select a project which is not a module suite using Browse…. However the suite may be omitted if Project Location is inside a netbeans.org CVS checkout (in which case the generated module will be a netbeans.org module).

Note that there is intentionally no option to Set as Main Project, since this is unlikely to be useful for such a project.

Library Wrapper Module Project Wizard—Basic Module Properties

...............................................................................
. Basic Module Properties                                                     .
. --------------------------------------------------------------------------- .
. Code _N_ame Base:      [org.apache.commons.logging________________________] .
. Module _D_isplay Name: [Apache Commons Logging____________________________] .
.                                                                             .
. _L_ocalizing Bundle:   [org/apache/commons/logging/Bundle.properties______] .
.                                                                             .
.                                                                             .
.                                                                             .
.                                                                             .
.                                                                             .
.                                                                             .
.                                                                             .
...............................................................................
                              [_B_ack]   Next>   [[_F_inish]] [Cancel] [_H_elp]

Code Name Base is a text field. Initial value: the name of a package in the (first) JAR file selected in the first panel which contains at least one *.class file and is of minimal length (i.e. do not pick a subpackage when a parent package is available), if such a package can be found; else blank.

Module Display Name is a text field. Initial value: Project Name from the previous panel.

Localizing Bundle is a text field. Initial value: Code Name Base with / in place of . and followed by /Bundle.properties (and tracking Code Name Base until explicitly edited).

Error conditions include:

  • Code Name Base is not a valid Java package name.

  • Some other module in the module universe is already using that code name base.

  • Module Display Name is blank.

  • Localizing Bundle does not end in .properties, or the path is not a valid Java package resource path.

Behavior upon Finish: a new module project is created (and appended to the selected suite). The selected JAR file(s) are copied into the release/modules/ext/ folder of the project directory. project.xml is initialized with <class-path-extension> element(s) specifying the library JAR(s), and <public-packages> enumerating every package in the JAR(s) which contains *.class files. No test/ directory is created; src/ is created but contains just the selected Bundle.properties in some package. If a license was selected, it is copied into the (top level of the) project directory, and nbm.license is set accordingly. The module is marked is.autoload=true.

New Module Suite Project—Wizard UI

User can select File | New Project and choose NetBeans Plug-in Modules as the category and Module Suite Project as the template.

New Module Suite Project Wizard—Name and Location

...............................................................................
. Name and Location                                                           .
. --------------------------------------------------------------------------- .
. Project _N_ame:      [suite1________________________________]               .
. Project _L_ocation:  [/src/mods_____________________________] [Br_o_wse...] .
. Project Fol_d_er:    /src/mods/suite1                                       .
. --------------------------------------------------------------------------- .
. NetBeans _P_latform: [NetBeans Platform 5.0_________________] [_M_anage...] .
.                                                                             .
. [X] Set as _M_ain Project                                                   .
.                                                                             .
.                                                                             .
.                                                                             .
.                                                                             .
...............................................................................
                              [_B_ack] [[Next>]]   _F_inish   [Cancel] [_H_elp]

All controls behave similarly to corresponding controls in the New Module Project wizard’s Name and Location panel, except that the default name should autoincrement suite1, suite2, etc.

Module Project Properties—Dialog UI

What you see when you ask for properties on a module project.

Dialog title is always Project Properties - modulename where modulename is the current value of OpenIDE-Module-Name in the localizing bundle. This display name is used in other places in the GUI, e.g. label in Projects tab, label in Open Project dialog, etc.

Many fields bound to entries in project.properties have default values, as documented in harness/README in the build; the default values should be displayed in the GUI in case the property is not defined explicitly (and editing the GUI to specify the default value should result in the removal of the entry from project.properties).

The module universe is the set of modules detected as binaries in the currently selected NetBeans Platform (with or without associated sources); plus all other (source) modules detected in the same module suite as this module. For netbeans.org modules, the module universe consists of all other modules in the same netbeans.org CVS checkout.

Module Project Properties Dialog—Sources Panel Selected

+----------------------------------------------------------------------------+
| Project Properties - Demo Module                                         X |
+----------------------------------------------------------------------------+
| Categories:                                                                |
| +----------------+                                                         |
| |[Sources]       | Project _F_older: /src/mods/module1                     |
| | Libraries      | Module _S_uite:   /src/mods/suite1                      |
| | Display        |                                                         |
| | API Versioning | Source _L_evel:   [1.4_______________________________v] |
| | Build          |                                                         |
| |   Compiling    |                                                         |
| |   Packaging    |                                                         |
| |                |                                                         |
| |                |                                                         |
| |                |                                                         |
| |                |                                                         |
| |                |                                                         |
| |                |                                                         |
| |                |                                                         |
| |                |                                                         |
| |                |                                                         |
| |                |                                                         |
| |                |                                                         |
| |                |                                                         |
| |                |                                                         |
| |                |                                                         |
| |                |                                                         |
| |                |                                                         |
| |                |                                                         |
| |                |                                                         |
| +----------------+                                                         |
|                                                   [[OK]] [Cancel] [_H_elp] |
+----------------------------------------------------------------------------+

Project Folder displays the location of the project directory.

Module Suite displays the location of the containing suite, if this is a suite component module. If it is a standalone module or a netbeans.org module, the field is blank and disabled.

Source Level is bound to javac.source in project.properties. Default (no explicit value) is 1.4. Options are 1.4 and 1.5.

Module Project Properties Dialog—Libraries Panel Selected

+--------------------------------------------------------------------------------------------+
| Project Properties - Demo Module                                                         X |
+--------------------------------------------------------------------------------------------+
| Categories:                                                                                |
| +----------------+                                                                         |
| | Sources        | _J_ava Platform:     [JDK 1.5___________v] [Mana_g_e Java Platforms...] |
| |[Libraries]     |                                                                         |
| |Display         | NetBeans _P_latform: [NetBeans Platform_v] [  _M_anage Platforms...   ] |
| |API Versioning  |                                                                         |
| |Build           | M_o_dule Dependencies:                                                  |
| |  Compiling     | +--------------------------------------------+                          |
| |  Packaging     | | Ant Module API                            ^| [ _A_dd Dependency...  ] |
| |                | | Filesystems API                           .| [ Add New _L_ibrary... ] |
| |                | | I/O APIs                                  .| [      _R_emove        ] |
| |                | |[Java Support APIs]                        .|                          |
| |                | | Loaders API                               v| [      _E_dit...       ] |
| |                | +--------------------------------------------+                          |
| |                |                                                                         |
| |                | Re_q_uired Tokens:                                                      |
| |                | +--------------------------------------------+                          |
| |                | |[org.netbeans.api.javahelp.Help]           ^| [       A_d_d...       ] |
| |                | |                                           v| [       Remo_v_e       ] |
| |                | +--------------------------------------------+                          |
| +----------------+                                                                         |
|                                                                   [[OK]] [Cancel] [_H_elp] |
+--------------------------------------------------------------------------------------------+

Java Platform displays the selected JDK. Enabled for standalone modules using a 5.0u1 harness or later, and netbeans.org modules, but not for suite component modules. Manage Java Platforms… brings up Java Platform Manager. If you switch to a JDK 5 platform (or newer) from a JDK 1.4 platform, you will also be prompted to add -Xlint:unchecked to your compiler arguments:

Enable JDK 5 Warnings

You have turned on support for JDK 5 language features including generics. Do you wish to enable compiler warnings regarding unchecked raw types? You can always customize compiler options in the Compiling panel. (Enable Warnings | Skip)

NetBeans Platform displays the selected platform. Choices are those platforms listed in the manager. Enabled only for standalone external modules, not netbeans.org modules nor modules which are part of a suite. Manage Platforms… opens the NetBeans Platform Manager dialog.

Required Tokens is bound to OpenIDE-Module-Requires in manifest.mf. Displays a list entry for each token (sorted alphabetically). Add pops up a simple dialog permitting one token to be selected from among a scrolling list of all available tokens, as computed by inspecting OpenIDE-Module-Provides among all modules in module universe, as well as any special tokens defined by the Modules API. Remove removes the selected item.

Module Dependencies shows a list of declared module dependencies, as <module-dependency>s in project.xml. Each list entry is displayed as the module’s localized display name. Shown sorted alphabetically.

Add Dependency… adds a new dependency (see below). The new dependency will initially request a major release version and specification version as taken from the module’s manifest and be included in the classpath if there are any available packages (as below). The new dependency will be selected so that Edit… may be used to customize it immediately. If multiple dependencies were added, just one of them will be selected automatically. In the case that the module is not a suite component the label will be just Add….

Add New Library… is present only in the case the module is a a suite component. It invokes Library Wrapper Module Project wizard in suite-dedicated mode for a suite the module belongs to. Besides of creation and registration of a new library wrapper in the suite; successfully finished wizard also adds the created wrapper into Module Dependencies list but do not write it into the module’s project.xml physically (yet). This will be eventually done in a standard way if the user confirms all properties changes. However even if the user cancels the properites dialog the added wrapper remains in the module’s suite (XXX consider removing it in this case).

Remove removes the selected dependency.

Edit… displays a subdialog displaying details of the dependency and permitting some details to be changed.

Module Project Properties—Libraries Tab—Add Module Dependency Subdialog

+----------------------------------------------------------------------------+
| Add Module Dependency                                                    X |
+----------------------------------------------------------------------------+
| _F_ilter: [(try class or package names; JAR paths; display or code names)] |
|                                                                            |
| [ ] Show _N_on-API Modules                                                 |
|                                                                            |
| _M_odule:                                                                  |
| +------------------------------------------------------------------------+ |
| | Actions APIs                                                          ^| |
| | Ant                                                                   .| |
| | Bean Patterns                                                         .| |
| | Core - IDE                                                            .| |
| |[Diff]                                                                 .| |
| | Editor Bookmarks                                                      .| |
| | Editor Code Folding                                                   v| |
| +------------------------------------------------------------------------+ |
|                                                                            |
| _D_escription:                                                             |
| +------------------------------------------------------------------------+ |
| | The Diff module provides an action, that is enabled when two files    ^| |
| | are selected in the IDE. It is based on an external diff utility,     v| |
| |                                                                        | |
| | Matching Filter Contents:                                              | |
| | no filter specified                                                    | |
| +------------------------------------------------------------------------+ |
|                                                                            |
| [Show _J_avadoc]                                                           |
|                                                                            |
|                                                   [[OK]] [Cancel] [_H_elp] |
+----------------------------------------------------------------------------+

Permits you to add a module as a dependency. If Show Non-API modules is checked, the available modules will include all modules in the module universe. If not (default), only modules with some public packages are included, or friend packages where this module is a friend - modules for which the current module could not access any packages without an Implementation dependency are excluded.
Shown modules are sorted alphabetically. List permits multiple selection.

Modules are displayed even if they are are already listed as dependencies for this module. If the user selects a module which this module already has a dependency on, and presses OK, no changes to the dependency list are made, but the chosen module is selected in the dependency list.

Modules which are marked as deprecated are shown in strikethrough.

Description displays the OpenIDE-Module-Long-Description of the selected module, if exactly one module is selected.

Show Javadoc displays Javadoc for the selected module in an external web browser. Enabled only if Javadoc for that module can be found.

Module Project Properties—Libraries Tab—Add Module Dependency—Filtering

+----------------------------------------------------------------------------+
| Add Module Dependency                                                    X |
+----------------------------------------------------------------------------+
| _F_ilter: [classpath_____________________________________________________] |
|                                                                            |
| [ ] Show _N_on-API Modules                                                 |
|                                                                            |
| _M_odule:                                                                  |
| +------------------------------------------------------------------------+ |
| |[Execution API]                                                         | |
| | Java Project APIs                                                      | |
| | Java Support APIs                                                      | |
| |                                                                        | |
| |                                                                        | |
| |                                                                        | |
| |                                                                        | |
| +------------------------------------------------------------------------+ |
|                                                                            |
| _D_escription:                                                             |
| +------------------------------------------------------------------------+ |
| | Consists of parts of the org.openide.execution.* package from the      | |
| | Open APIs.                                                             | |
| |                                                                        | |
| | Matching Filter Contents:                                              | |
| | org.openide.execution.NbClassPath                                      | |
| +------------------------------------------------------------------------+ |
|                                                                            |
| [Show _J_avadoc]                                                           |
|                                                                            |
|                                                   [[OK]] [Cancel] [_H_elp] |
+----------------------------------------------------------------------------+

Filter lets you type in a search string to narrow down the list. When there is text in this field, only those modules are displayed which include the search string as a case-insensitive substring of any of

  1. their code name base
  2. their localized display name
  3. the full path to their module JAR or any Class-Path extension
  4. the fully-qualified class name (use . for inner classes) of any class contained in their module JAR or any Class-Path extension which is in an package which would be made available to this module when using a specification version dependency (as above). Note that this means that (fragments of) package names and unqualified class names which you wish to import in your Java source code, or found in API documentation, can be used as filters.

After new filter text has been typed, update begins immediately, but the list displays only Please Wait… until all the results have been computed (or the filter text is again changed).

As with the Fast Open dialog, keys such as Up, Down, Page Up, and Page Down should apply to the Module list even if Filter has keyboard focus.

Filterable tokens (e.g. fully-qualified class names) which match the current filter string are displayed in the description area to assist the user to discover what can be searched for. Matching portions are highlighted in yellow (akin to editor search results).

Module Project Properties—Libraries Tab—Edit Module Dependency Subdialog

+----------------------------------------------------------------------------+
| Module Dependency - Demo Module on Java Support APIs                     X |
+----------------------------------------------------------------------------+
| Code _N_ame Base:            org.netbeans.api.java                         |
| JA_R_:                       ...bp50/ide/modules/org-netbeans-api-java.jar |
|                                                                            |
| Ma_j_or Release Version:     [1__________________________________________] |
| (X) _S_pecification Version: [1.8________________________________________] |
| ( ) _I_mplementation Version                                               |
|                                                                            |
| [X] Include API Packages in _C_lasspath:                                   |
| +------------------------------------------------------------------------+ |
| | org.netbeans.api.java.classpath                                       ^| |
| | org.netbeans.api.java.queries                                         v| |
| +------------------------------------------------------------------------+ |
|                                                                            |
| [Show Javad_o_c]                                                           |
|                                                                            |
|                                                   [[OK]] [Cancel] [_H_elp] |
+----------------------------------------------------------------------------+

Code Name Base displays the CNB of the dependent module.

Major Release Version gives the major release version requested in the dependency. (May be blank, a nonnegative integer, or a range of increasing nonnegative integers separated by - such as 1-2.)

Specification Version, if the radio button is selected, also lets the minimum version number be entered. (May be blank.) Text field enabled only if radio button is selected.

Implementation Version may be selected instead. You cannot enter a version string in this case.

JAR displays the full path the dependent module JAR file.

Include in Classpath may be checked to indicate that you wish to compile against that module (not just depend on it at runtime). Enabled only if Available Packages is not empty, else disabled and unchecked.

Available Packages displays packages you could compile against from that module. Computed from the packages available in the dependent module JAR (and its Class-Path extensions). If Implementation Version is selected, all such packages are shown. Else (Specification Version selected), only those packages matching OpenIDE-Module-Public-Packages in the dependent module’s manifest are listed. If the dependent module specifies OpenIDE-Module-Friends, its public packages are listed only if the module whose properties are being shown is in fact among the listed friends.

Show Javadoc displays Javadoc for the selected dependency in an external web browser. Enabled only if Javadoc for that module can be found (according to NetBeans Platform Manager).

Module Project Properties Dialog—Display Panel Selected

+----------------------------------------------------------------------------+
| Project Properties - Demo Module                                         X |
+----------------------------------------------------------------------------+
| Categories:                                                                |
| +----------------+                                                         |
| | Sources        | Display _N_ame:      [Demo Module_____________________] |
| | Libraries      | Display _C_ategory:  [Infrastructure_________________v] |
| |[Display]       | _S_hort Description: [Demo module to try out stuff.___] |
| | API Versioning | _L_ong Description:                                     |
| | Build          | +-----------------------------------------------------+ |
| |   Compiling    | | A lengthier description here. Etc.                 ^| |
| |   Packaging    | |                                                    .| |
| |                | |                                                    v| |
| |                | +-----------------------------------------------------+ |
| |                |                                                         |
| |                |                                                         |
| |                |                                                         |
| |                |                                                         |
| |                |                                                         |
| |                |                                                         |
| |                |                                                         |
| |                |                                                         |
| |                |                                                         |
| |                |                                                         |
| |                |                                                         |
| |                |                                                         |
| |                |                                                         |
| |                |                                                         |
| |                |                                                         |
| |                |                                                         |
| +----------------+                                                         |
|                                                   [[OK]] [Cancel] [_H_elp] |
+----------------------------------------------------------------------------+

Display Name is bound to OpenIDE-Module-Name in the localizing bundle.

Display Category is bound to OpenIDE-Module-Display-Category. It is an editable combo box; choices include OpenIDE-Module-Display-Categorys already used in the module universe.

Short Description is bound to OpenIDE-Module-Short-Description.

Long Description is bound to OpenIDE-Module-Long-Description. This text area line wraps automatically (at word boundaries). If changes are made, the value stored in the localized bundle is split into lines—one per sentence.

Module Project Properties Dialog—API Versioning Panel Selected

+----------------------------------------------------------------------------+
| Project Properties - Demo Module                                         X |
+----------------------------------------------------------------------------+
| Categories:                                                                |
| +----------------+                                                         |
| | Sources        | Code _N_ame Base:         org.netbeans.module.demo      |
| | Libraries      | Ma_j_or Release Version:  [___________________________] |
| | Display        |                                                         |
| |[API Versioning]| _S_pecification Version:  [1.0________________________] |
| | Build          | [ ] A_p_pend Implementation Versions Automatically      |
| |   Compiling    | _I_mplementation Version: [___________________________] |
| |   Packaging    |                                                         |
| |                | Module Type: (*) Re_g_ular ( ) Auto_l_oad ( ) _E_ager   |
| |                |                                                         |
| |                | P_u_blic Packages:                                      |
| |                | +---+-------------------------------------------------+ |
| |                | |[X]| org.netbeans.api.demo                          ^| |
| |                | |[ ]| org.netbeans.modules.demo                      .| |
| |                | |[ ]| org.netbeans.modules.demo.ui                   .| |
| |                | |   |                                                v| |
| |                | +---+-------------------------------------------------+ |
| |                |                                                         |
| |                | [ ] Export Packages Only to _F_riends:                  |
| |                | +------------------------------------------+            |
| |                | |                                         ^| [_A_dd...] |
| |                | |                                         v| [_R_emove] |
| |                | +------------------------------------------+            |
| |                |                                                         |
| |                | Pro_v_ided Tokens:        [___________________________] |
| +----------------+                                                         |
|                                                   [[OK]] [Cancel] [_H_elp] |
+----------------------------------------------------------------------------+

Code Name Base displays the code name base of the module.

Major Release Version lets you set the major release version in manifest.mf; may be blank or a nonnegative integer.

Specification Version is bound to OpenIDE-Module-Specification-Version in manifest.mf, or to spec.version.base in project.properties in case Append Implementation Versions Automatically is checked. This checkbox is enabled only if Implementation Version is not blank, and/or there is at least one implementation dependency listed in the Libraries panel.

Implementation Version is bound to OpenIDE-Module-Implementation-Version in manifest.mf. May be blank.

Regular Module, Autoload Module, and Eager Module are bound to is.autoload and is.eager in project.properties.

Public Packages displays a table listing all packages contained in the source directory plus any <class-path-extension>s. If checked, the package is included among <public-packages> in project.xml.

Export Packages Only to Friends is a noneditable checkbox; it is checked if and only if there is at least one entry in the list below it. The list may include code name bases of other modules and is sorted. If not empty, packages are kept in <friend-packages> instead and the friends are listed in project.xml. Add… displays a small dialog (below).

Provided Tokens is bound to OpenIDE-Module-Provides in manifest.mf.

Error conditions include:

  • Export Packages Only to Friends is checked (i.e. there is at least friend module entry) yet there are no checked packages in Public Packages.

  • Implementation Versions is not blank but is not an integer. (Does not work with spec.version.base.)

Module Project Properties Dialog—API Versioning Panel—Add New Friend Module

+----------------------------------------------------------------------------+
| Add New Friend Module                                                    X |
+----------------------------------------------------------------------------+
| _F_riend Module: [org.yourorghere.module2_______________________________v] |
|                                                                            |
|                                                                            |
|                                                   [[OK]] [Cancel] [_H_elp] |
+----------------------------------------------------------------------------+

Friend Module is an editable combo box. Its initial values are a sorted list of code name bases of all modules in the same suite (for a suite component module; or all other modules, for a netbeans.org module; no entries for a standalone module). In particular, binary modules from the platform are not to be listed (though the user is not prevented from entering one manually). There is no initial selection.

OK adds the new module to the Export Packages Only to Friends list in the API Versioning panel, and selects the new entry.

Error conditions include:

  • The field is empty.

  • The field is not a valid Java package name.

Module Project Properties Dialog—Build | Compiling Panel Selected

+----------------------------------------------------------------------------+
| Project Properties - Demo Module                                         X |
+----------------------------------------------------------------------------+
| Categories:                                                                |
| +----------------+                                                         |
| | Sources        | [X] _G_enerate Debugging Info                           |
| | Libraries      | [X] Report Uses of _D_eprecated APIs                    |
| | Display        |                                                         |
| | API Versioning | Additional Compiler _O_ptions: [______________________] |
| | Build          |                                                         |
| |  [Compiling]   |                                                         |
| |   Packaging    |                                                         |
| |                |                                                         |
| |                |                                                         |
| |                |                                                         |
| |                |                                                         |
| |                |                                                         |
| |                |                                                         |
| |                |                                                         |
| |                |                                                         |
| |                |                                                         |
| |                |                                                         |
| |                |                                                         |
| |                |                                                         |
| |                |                                                         |
| |                |                                                         |
| |                |                                                         |
| |                |                                                         |
| |                |                                                         |
| |                |                                                         |
| +----------------+                                                         |
|                                                   [[OK]] [Cancel] [_H_elp] |
+----------------------------------------------------------------------------+

Generate Debugging Info is bound to build.compiler.debug.

Report Uses of Deprecated APIs is bound to build.compiler.deprecation.

Additional Compiler Options is bound to javac.compilerargs. Enabled when using a 5.0u1 harness or later.

Module Project Properties Dialog—Build | Packaging Panel Selected

+----------------------------------------------------------------------------+
| Project Properties - Demo Module                                         X |
+----------------------------------------------------------------------------+
| Categories:                                                                |
| +----------------+                                                         |
| | Sources        | _J_AR File: ...tra/modules/org-netbeans-module-demo.jar |
| | Libraries      |                                                         |
| | Display        | NBM Package Metadata                                    |
| | API Versioning | ------------------------------------------------------- |
| | Build          | [ ] Needs _R_estart on Install                          |
| |   Compiling    | [ ] Must be Installed _G_lobally                        |
| |  [Packaging]   |                                                         |
| |                | _L_icense:   [../lgpl.txt_______________] [Bro_w_se...] |
| |                | Home _P_age: [http://nowhere.net/demo-module.html_____] |
| |                | _A_uthor:    [John Q. Hacker__________________________] |
| |                |                                                         |
| |                |                                                         |
| |                |                                                         |
| |                |                                                         |
| |                |                                                         |
| |                |                                                         |
| |                |                                                         |
| |                |                                                         |
| |                |                                                         |
| |                |                                                         |
| |                |                                                         |
| |                |                                                         |
| |                |                                                         |
| |                |                                                         |
| |                |                                                         |
| +----------------+                                                         |
|                                                   [[OK]] [Cancel] [_H_elp] |
+----------------------------------------------------------------------------+

JAR File gives the actual JAR file that will be created for the module, as ${cluster}/${module.jar}.

Needs Restart on Install is bound to nbm.needs.restart.

Must be Installed Globally is bound to nbm.is.global.

License points to a license file for the NBM (or may be blank). Bound to license.file. May be an absolute or (project-)relative path. (When using the Browse… button, the path is set as relative if the selected file is inside the module suite root.) Disabled for netbeans.org modules.

Home Page should be a URL (or blank). Bound to nbm.homepage.

Author may be any text (or blank). Bound to nbm.module.author.

Module Suite Project Properties Dialog

Module Suite Project Properties Dialog—Sources Panel Selected

+-------------------------------------------------------------------------------+
| Suite Project Properties - Demo Suite                                       X |
+-------------------------------------------------------------------------------+
| Categories:                                                                   |
| +-------------------+                                                         |
| |[Sources]          | Project _F_older: /src/mods/suite1                      |
| | Libraries         |                                                         |
| | Application       | Suite _M_odules:                                        |
| |   Splash Screen   | +------------------------------------------+            |
| |                   | |[Demo Module #1]                          | [_A_dd...] |
| |                   | | Demo Module #2                           | [_R_emove] |
| |                   | |                                          |            |
| |                   | |                                          |            |
| |                   | |                                          |            |
| |                   | |                                          |            |
| |                   | |                                          |            |
| |                   | |                                          |            |
| |                   | |                                          |            |
| |                   | |                                          |            |
| |                   | |                                          |            |
| |                   | |                                          |            |
| |                   | |                                          |            |
| |                   | |                                          |            |
| |                   | |                                          |            |
| |                   | |                                          |            |
| |                   | |                                          |            |
| |                   | |                                          |            |
| |                   | |                                          |            |
| |                   | |                                          |            |
| |                   | +------------------------------------------+            |
| +-------------------+                                                         |
|                                                      [[OK]] [Cancel] [_H_elp] |
+-------------------------------------------------------------------------------+

Project Folder displays the location of the project directory.

Modules displays an alphabetized list of modules currently contained in the suite (showing their display name). The tool tip for each entry should give the absolute path to the module’s project directory for disambiguation.

Add… adds a new module to the suite. It invokes the usual Add Project dialog. If the user adds a module which is already in the list, it is just selected. If the user tries to add a module which is not an NBM project (currently the Add Project dialog SPI does not permit filters to exclude unwanted projects), an error dialog is displayed:

The project "My First Web App" is not a NetBeans module project. You can only add NetBeans modules to a module suite. [[OK]]

If the module was a standalone module, it is converted to be a suite component module; if it was a component of another suite, the user is prompted with a question dialog:

Module "Demo Module #3" is already part of the module suite "Demo Suite #2" [/src/mods/suite2]. Do you wish to remove the module from that suite and add it to "Demo Suite #1" instead? [[OK]] [Cancel]

Remove removes the selected module from the list.

Module Suite Project Properties Dialog—Libraries Panel Selected


+---------------------------------------------------------------------------------------------+
| Suite Project Properties - Demo Suite                                                     X |
+---------------------------------------------------------------------------------------------+
| Categories:                                                                                 |
| +-----------------+                                                                         |
| | Sources         | _J_ava Platform:     [JDK 1.5___________v] [Mana_g_e Java Platforms...] |
| |[Libraries]      |                                                                         |
| | Application     | NetBeans _P_latform: [NetBeans Platform_v] [  _M_anage Platforms...   ] |
| |   Splash Screen |                                                                         |
| |                 | Platform _M_odules:                                                     |
| |                 | +----------------------------------------+----------------------------+ |
| |                 | | Clusters and Modules                   | Included                   | |
| |                 | +----------------------------------------+----------------------------+ |
| |                 | | + enterprise2                          |  [ ]                       | |
| |                 | | + harness                              |  [ ]                       | |
| |                 | | - platform6                            |  [/]                       | |
| |                 | |     Bootstrap                          |  [X]                       | |
| |                 | |     Core                               |  [X]                       | |
| |                 | |     Core Startup                       |  [X]                       | |
| |                 | |     JavaHelp                           |  [ ]                       | |
| |                 | |                                        |                            | |
| |                 | |                                        |                            | |
| |                 | |                                        |                            | |
| |                 | |                                        |                            | |
| |                 | |                                        |                            | |
| |                 | |                                        |                            | |
| |                 | +----------------------------------------+----------------------------+ |
| +-----------------+                                                                         |
|                                                                    [[OK]] [Cancel] [_H_elp] |
+---------------------------------------------------------------------------------------------+

Java Platform displays the selected JDK. Enabled for a 5.0u1 harness or later. Manage Java Platforms… brings up Java Platform Manager.

NetBeans Platform and Manage Platforms… behave as in the Libraries panel for the module project properties dialog.

Basic customization of any application on top of the NetBeans platform requires selection of modules from the platform to be included in the resulting application. Modules directly used by suite modules (e.g. as compile-time dependencies) must be included; other modules (such as Favorites) may not be directly required by any suite module, yet the application author may nonetheless wish to include them for their exposed functionality. Even when building a suite of IDE plug-in modules (generally, where application mode is disabled), it can be useful to exclude some platform modules if they will not be required by your modules.

NetBeans-based platforms are organized by cluster, so in simple cases the application author can decide what to include at cluster granularity. For example, the NetBeans IDE can be selected as a target platform while actually only using the NetBeans Platform subset (the cluster currently named platform6). However, the user may decide to include only some modules from a cluster and not others.

To support these options, the UI displays a tree table Platform Modules, with modules (as display names and sorted alphabetically) shown beneath clusters (as folder names and sorted alphabeticaly). If a cluster is unchecked, nothing from it is included in the application. If checked, every module in that cluster is included. There is also a partially checked state in case some, but not all, modules in the cluster are included. (The modules in the suite are not displayed—they are always included in the application.) The IDE stores a list of module and cluster excludes (not includes), so that if a selection is made in NetBeans Platform later, newly present clusters and/or modules will be included until explicitly excluded. The tooltip for each module shows its code name base and its short description (if any).

To help the user decide which modules to include, the IDE rechecks module dependencies whenever any checkbox is toggled. If there are any predicted problems (that would result in a module not being loadable in the running application), a warning message appears at the base of the dialog. Examples of such warnings:

  • Module FeedReader depends on module Actions API in cluster platform6 but this is excluded.
  • Module User's Guide in cluster ide6 requests the token org.netbeans.api.javahelp.Help but all providers (e.g. module JavaHelp Integration in cluster platform6) are excluded.

Module Suite Project Properties Dialog—Application Panel Selected

+------------------------------------------------------------------------------------------+
| Suite Project Properties - Demo Suite                                                  X |
+------------------------------------------------------------------------------------------+
| Categories:                                                                              |
| +--------------------+                                                                   |
| | Sources            | ( ) Create Collection of Add-on _M_odules                         |
| | Libraries          | (X) Create Standalone _A_pplication                               |
| |[Application]       |                                                                   |
| |   Splash Screen    | Branding _N_ame:          [myapp________________________________] |
| |                    |                                                                   |
| |                    | Application _T_itle:      [My Application_______________________] |
| |                    | Application Icon (48x48): +------+                  [Bro_w_se...] |
| |                    |                           | **** |                                |
| |                    |                           |******|                                |
| |                    |                           | **** |                                |
| |                    |                           +------+                                |
| |                    |                                                                   |
| |                    |                                                                   |
| |                    |                                                                   |
| |                    |                                                                   |
| |                    |                                                                   |
| +--------------------+                                                                   |
|                                                                 [[OK]] [Cancel] [_H_elp] |
+------------------------------------------------------------------------------------------+

If Create Standalone Application is selected (Create Collection of Add-on Modules is selected by default), the suite is set up for creation of an application, rather than a set of add-on modules. The remaining controls, and the subpanel Splash Screen, are enabled only when this is selected.

If Create Standalone Application is selected by the user when Create Collection of Add-on Modules was selected before, and there were not already any modules or clusters excluded from the list in Libraries, a confirmation dialog is displayed:

Exclude IDE Modules

Do you wish to exclude IDE-related modules from your application now? You can always customize the list of platform modules included in your application in the Libraries panel. (Exclude | Skip)

If the user accepts the dialog, the module list will be edited to exclude:

  1. All clusters other than platform6.

  2. The platform modules Auto Update (meaningless in JNLP mode and not necessarily desirable in other applications); Execution API, Core - Execution, Input/Output APIs, Output Window, and Multi-View Windows (not very likely to be wanted in non-IDE-oriented applications, and can add undesirable GUI elements in JNLP mode); Favorites as that are needed only for applications accessing local files; Deprecated Compatibility APIs and Deprecated Enumeration APIs (only exist for compatibility with old modules).

Branding Name is bound to app.name and will control the application’s branding token (branding.token), as well as filenames for ZIP and JNLP distribution, the launcher executable name, and so on.

Application Title is bound to app.title and will be displayed e.g. in the main window title of the application.

48x48 Icon is an icon to use for the application. Currently only controls the main window icon and the JNLP application icon. Only a preview is shown, since the actual icon is always stored as branding/core/core.jar/org/netbeans/core/startup/frame48.gif in the suite project; Browse… lets the user pick a new image of the correct size. Initially set to the platform’s unbranded icon.

Error conditions include:

  • Branding Name does not match the restricted character set and pattern used for branding tokens. (Basically just one or more lowercase alphanumeric segments separated by underscores, similar to Java locale and country codes.)

Module Suite Project Properties Dialog—Splash Screen Panel Selected

+--------------------------------------------------------------------------------------------------------+
| Suite Project Properties - Demo Suite                                                                X |
+--------------------------------------------------------------------------------------------------------+
| Categories:                                                                                            |
| +--------------------+                                                                                 |
| | Sources            | Progress Bar:                                                                   |
| | Libraries          |   [X] _E_nabled        _C_olor: [orange_____v...]  _P_ositioning: [1,2,3,4_...] |
| | Application        |                                                                                 |
| |  [Splash Screen]   | Running Text:                                                                   |
| |                    |   _S_ize: [12_______]  Colo_r_: [yellow_____v...]  Positio_n_ing: [5,6,7,8_...] |
| |                    |                                                                                 |
| |                    | Splash Screen:                                                                  |
| |                    | +---------------------------------------------------------------+               |
| |                    | |...............................................................| [Bro_w_se...] |
| |                    | |...............................................................|               |
| |                    | |...............................................................|               |
| |                    | |...............................................................|               |
| |                    | |...sample text sample text sample text sample text sample te...|               |
| |                    | |...=========================================================...|               |
| |                    | |...............................................................|               |
| |                    | +---------------------------------------------------------------+               |
| +--------------------+                                                                                 |
|                                                                               [[OK]] [Cancel] [_H_elp] |
+--------------------------------------------------------------------------------------------------------+

Lets the user customize the application’s splash screen. The basic background image is selected with Browse…; only a preview is shown, as the actual image is always stored as branding/core/core.jar/org/netbeans/core/startup/splash.gif in the suite project. Initially the platform’s unbranded splash screen.

A progress bar is displayed if Enabled is checked (checked by default), in the Color selected (initially the platform’s unbranded color). The Color field is a color property editor as used e.g. in the form editor. The position and (maximum) size of the progress bar may be changed using drag-and-drop; or using Positioning, a property editor for rectangles (x, y, width, height) as used e.g. in the form editor.

Running text for status messages is shown as sample text sample text… to fill the allotted space. Size controls the size in points. Color controls the text color. Positioning controls the position and (maximum) size of the text bar, which may also be changed using drag-and-drop.

After selecting a splash screen of a different size, the progress bar and running text positions and sizes may be automatically adjusted to fit within the new splash bounds. The splash preview area may add scrollbars if a large splash screen is selected.

Error conditions include:

  • The progress and/or running text bounds do not within the dimensions of the selected splash screen.

Module Logical View—Node and Action UI

As seen when a module is open in Projects. Precise appearance may vary according to whether the module is inside the netbeans.org CVS tree or not.

Module Logical View—Nodes

TREE STRUCTURE                  COMMENTS, FILE LOCATION, ETC.
-----------------------------   -------------------------------------------------
Demo Module                     root node named acc. to OpenIDE-Module-Name
  Source Packages               src/
    org.netbeans.modules.demo
      SomeClass.java
  Unit Test Packages            test/unit/src/ if present; can be others
    org.netbeans.modules.demo
      SomeClassTest.java
  Libraries
    JDK 1.5 (default)
      rt.jar
        ....
        java.io
          ....
          IOException.class
          ....
        ....
      ....
    Utilities API
    My Library Module
    ....
  Unit Test Libraries
    junit-3.8.1.jar
      junit.framework
        TestCase.class
        ....
      ....
    ....
Important Files                 whatever is available...
  XML Layer                     OpenIDE-Module-Layer
    <this layer>                just this layer considered in isolation
      Templates
        Projects
          My New Project
    <this layer in context>     this layer merged with target platform & suite
      File
      Templates
      ...
  Module Manifest Prototype     ${manifest.mf}
  Build Script                  build.xml
  Project Metadata              nbproject/project.xml
  Project Properties            nbproject/project.properties
  Per-user Project Properties   nbproject/private/private.properties
  Suite Locator                 nbproject/suite.properties [suite comp. only]
  Per-user Suite Locator        nbproject/private/suite-private.properties [suite comp. only]
  NetBeans Platform Config      nbproject/platform.properties [standalone only]
  Per-user NB Platform Config   nbproject/private/platform-private.properties [standalone only]
  Architecture Description      ${javadoc.arch} [usually netbeans.org only]
  API Changes                   ${javadoc.apichanges} [usually netbeans.org only]
  Javadoc Overview              ${javadoc.overview} [usually netbeans.org only]

<this layer> displays a structural filesystem view of the XML layer. Changes made (e.g. using Open, Rename, Delete, New…, or generally as for any files and folders e.g. in Favorites) are applied to the XML layer text (which is autosaved) and if applicable also to external files referred to from the layer. Files and folders may display localized names and icons according to the usual XML layer semantics. Context menu item Localize Name… lets you enter a new localized name (affects the XML layer and the localizing bundle). Pick Icon… lets you select a new icon using a filechooser (it will be copied into the module’s source tree if not there already).

<this layer in context> behaves similarly but shows a merged filesystem including not only this module’s layer but layers of other modules in its suite (for suite component modules), of non-excluded platform modules (for external modules), and of other netbeans.org modules in the official clusters (for netbeans.org modules). Changes made in this view are still applied to this module’s XML layer text but may result in branding overrides (e.g. *_hidden files if nonlocal files or folders are Deleted). Files or folders contributed by this module’s layer are boldfaced. Localize Name… and Pick Icon… are available only for the locally contributed files and folders.

No explicit action to add any of these files is planned. For the most part, they are either created as part of the module (e.g. Build Script); or added implicitly somehow (e.g. template for ModuleInstall in Phase IV GUI should cause a node like DemoModuleInstaller.java to appear as a side effect); or are primarily used within netbeans.org and not of much interest to external module developers (e.g. API Changes).

The node Libraries displays the classpath of Source Packages. The first subnode displays the JDK used to build the module. Subnodes which refer to module JARs for which sources are available—either modules in the same suite, or in the target platform but with source association working—are displayed as project nodes with no children. Subnodes which refer to other JARs just display the JAR file with *.class beneath it in a package list. As in other project types, Open Project, Open, Show Javadoc, and Find… actions may be available in the context menus of appropriate subnodes. The context menu of Libraries includes a menu item Add Module Dependency… which displays the Add Module Dependency dialog without opening the project properties dialog. In the case of a suite component there will be also Add New Library… item which invokes Library Wrapper Module Project wizard in suite-dedicated mode for a suite the module belongs to—besides of creation and registration of a new library wrapper in the suite; successfully finished wizard also add a dependency into the module’s project.xml. Direct children of Libraries which correspond to module dependencies may be Removed as well as Edit…ed (displays the Edit Module Dependency dialog).

Also Unit Test Libraries should be displayed for the classpath of Unit Test Packages if it exists, and analogously for any other test source folders in the project. Entries which are already displayed beneath Libraries (such as for dependent modules) should not be duplicated here—only display classpath entries specific to the test source root. There is currently no way to add entries to it from the GUI.

Module Logical View—Actions

Context menu of root node:

MENU ITEMS                         COMMENTS, ANT TARGET, ETC.
---------------------------------  -----------------------------------------------------------
New >                              usual New action
      File/Folder...
      ----------------
      Java Class...
      Java Package...
      Java Interface...
      Test for Existing Class...
      Action...                    see Phase IV wizard specs
      J2SE Library Descriptor...   "
      File Type...                 "
      Project Template...          "
      Window Component...          "
      Wizard...                    "
---------------------------------
Build                              build.xml#netbeans
Clean and Build                    build.xml#clean,netbeans
Clean                              build.xml#clean
---------------------------------
Build with Dependencies            ${nb_all}/nbbuild/build.xml#init,all-${path} [nb.org only]
Build with Dependencies and Try    ${nb_all}/nbbuild/build.xml#init,all-${path},tryme [nb.org only]
Run                                build.xml#run
Debug                              build.xml#debug
---------------------------------
Run Unit Tests                     build.xml#test
Run Unit Tests using XTest         test/build.xml#cleanresults,runtests,show-results-nb
                                     -Dxtest.testtype=unit [netbeans.org only]
Measure Unit Test Coverage         test/build.xml#cleanresults,coverage,show-coverage-results
                                     -Dxtest.testtype=unit [netbeans.org only]
Build Functional Tests             test/build.xml#buildtests -Dxtest.testtype=qa-functional
                                     [netbeans.org only]
Run Functional Tests using XTest   test/build.xml#cleanresults,runtests,show-results-nb
                                     -Dxtest.testtype=qa-functional [netbeans.org only]
Build Performance Tests            test/build.xml#buildtests -Dxtest.testtype=qa-performance
                                     [netbeans.org only]
Run Performance Tests using XTest  test/build.xml#cleanresults,runtests,show-results-nb
                                     -Dxtest.testtype=qa-performance [netbeans.org only]
---------------------------------
Generate Javadoc                   build.xml#javadoc-nb
Generate Architecture Description  build.xml#arch-nb
---------------------------------
Check for Unused Bundle Keys       ${nb_all}/nbbuild/monitor.xml#check-bundle-usage
                                     -Dfixedmodules= -Dmodules=${path} [netbeans.org only]
---------------------------------
Install/Reload in Target Platform  build.xml#reload
Install/Reload in Development IDE  build.xml#reload-in-ide
Create NBM                         build.xml#nbm
---------------------------------
Set Main Project                   as usual
Open Required Projects             opens module projects
Close Project                      as usual
---------------------------------
Find...                            as usual
---------------------------------
Rename Project                     see below
Move Project                       see below
Copy Project                       see below
Delete Project                     see below
---------------------------------
CVS > ...                          as usual
---------------------------------
Tools > ...                        may be empty
---------------------------------
Properties                         opens properties dialog

If Generate Javadoc is selected and the module currently has no public packages, a dialog is displayed:

Javadoc cannot be produced for this module. It is not yet configured to export any packages to other modules.

The user can select Configure Public Packages… (default button) or Cancel. If the former, the properties dialog is opened, with the Public Packages area of the Versioning panel visible. No Javadoc is generated until the user configures one or more public packages and chooses Generate Javadoc again.

Install/Reload in Development IDE is always enabled for netbeans.org modules; for external modules, it is enabled only if the associated target platform is the default platform, and (in the case of suite component modules) there are no module or cluster exclusions currently in effect. Even if enabled, when selected it will prompt the user with a confirmation dialog before running:

Reloading a module in the running development IDE can be dangerous. Errors in the module could corrupt your environment and force you to use a new user directory. (In most cases it is wiser to use Install/Reload in Target Platform.) Do you really want to reload this module in your own IDE? (OK / Cancel)

If the user selects OK, the action is run and the warning is not displayed again.

Rename Project basic behavior is the same as with other project types. If you check the option Also Rename Project Folder the text given in the Project Name field will be applied to both—project folder name and project’s Display Name. In the case of renaming project folder of a suite component the suite’s metadata files are updated accordingly.

Move Project behaves in the same manner as Rename action (with Also Rename Project option checked) described above. Display Name is kept.

Copy Project behaves normally as with other project types. However if copied module is a suite component the target copy will be a standalone module with a name Source Display Name (0). I.e. appendix (0) is added.

Delete Project behaves normally as with other project types. If the being deleted module is a suite component and is set as a dependency in other suite component(s) the dependencies on this module will be automatically removed.

Module Suite Logical View—Nodes

Demo Suite
  Modules
    Demo Module #1
    Demo Module #2
  Important Files
    JNLP Descriptor                     master.jnlp
    Build Script                        build.xml
    Project Properties                  project.properties
    Per-user Project Properties         private.properties
    NetBeans Platform Config            platform.properties
    Per-user NetBeans Platform Config   platform-private.properties

Modules enumerates all modules contained in the suite. The context menu has three items: Add New…, launching the New Project wizard with the Module Project template selected; Add New Library…, launching the New Project wizard with the Library Wrapper Module Project template selected; and Add Existing…, identical to the Add… button on the Sources panel of the suite project properties dialog. Each module subnode has no children and the context menu contains just Open Project and Remove. If the being removed module is set as a dependency in other suite component(s) the user is prompted with a question dialog:

Important Files lists files that are considered important to be presented in the logical view. The JNLP descriptor is shown if and when it is generated. This happens when the suite is run for the first time as a JNLP application, or the JNLP application is built.

The module Demo Suite Component is set as a dependency in the following modules.

  • Other Suite Component
  • Another Suite Component

By removing this module from the suite the dependencies on this module will be removed as well.

[[OK]] [Cancel]

If there is not any dependency to the module no question dialog appears.

Module Suite Logical View—Actions

New >                          as usual
      File/Folder...
      -------------------
      Empty Ant Script...
      Properties File...
-----------------------------
Build All                      builds all submodules in order
Clean and Build All            clean build
Clean All                      cleans all submodules and other build products
-----------------------------
Run                            start app in normal mode (using netbeans or nbexec)
Debug                          start app in debugger
-----------------------------
Build ZIP Distribution         build ZIP of complete app incl. any launchers
-----------------------------
Build JNLP Application         build JNLP including final *.war
Run JNLP Application           run master.jnlp using javaws locally
Debug JNLP Application         same but with debugger
-----------------------------
Create NBMs                    build NBMs plus update descr. (5.0u1+ harness only)
-----------------------------
Set Main Project               as usual
Open Required Projects         opens module projects
Close Project                  as usual
-----------------------------
Find...                        as usual
-----------------------------
Rename Project                 see below
Move Project                   see below
Delete Project                 see below
-----------------------------
CVS > ...                      as usual
-----------------------------
Tools > ...                    may be empty
-----------------------------
Properties                     opens properties dialog

If one of the …JNLP Application menu items is selected and the module currently has no basic branding, a dialog is displayed:

The JNLP application cannot be built because this suite is not yet set up as a standalone application. At least a branding name must be configured before building or running in JNLP mode.

The user can select Configure Application… (default button) or Cancel. If the former, the properties dialog is opened, with the Application panel visible. No action occurs until the user configures basic branding and chooses the menu item again.

Rename Project basic behavior is the same as with other project types. If you check the option Also Rename Project Folder:

  • the text given in the Project Name field will be applied to both—project folder name and project’s Display Name.

  • All relative suite components—those of which project’s directory is a subdirectory of the suite directory; will be moved together with the suite. Other suite components component are not moved.

  • Metadata of a suite and all of its suite components are updated accordingly.

Move Project behaves in the same manner as Rename action (with Also Rename Project option checked) described above. Display Name is kept.

Delete Project behaves normally as with other project types. All suite components in the being deleted suite become standalone modules—i.e. are not deleted.

Copy Project for suite is not implemented yet (see issue 71544).

New J2SE Library Descriptor—Wizard UI

Not to be confused with the Library Wrapper Module Project, this feature is about making a JAR available as a registered library for end users, not using the JAR in your module.

Invoked as File | New File… and selecting category NetBeans Module Development and file type J2SE Library Descriptor. HTML description of template:

Use this template to add a new class library to the Library Manager of the user’s IDE. Select a library you have already defined in your own IDE. You may include associated sources and/or Javadoc.

New J2SE Library Descriptor Wizard—Select Library

+---------------------------------------------------------------------------------+
| New J2SE Library Descriptor                                                     |
+---------------------------------------------------------------------------------+
| Select Library                                                                  |
| ------------------------------------------------------------------------------- |
|                                                                                 |
| ( ) Existing _L_ibrary:                                                         |
|     [Absolute Layout_________________________________________________________v] |
|                                                                                 |
| (*) _C_ustom Library:                                                           |
|      ___________  __________  __________                                        |
|     / Classes   \/ Sources  \/ Javadoc  \                                       |
|     |            \----------------------------------------+                     |
|     | Library Classpath:                                  |                     |
|     | +---------------------------+                       |                     |
|     | | xerces.jar                | [ Add JAR/Folder... ] |                     |
|     | |                           |                       |                     |
|     | |                           | [       Remove      ] |                     |
|     | |                           |                       |                     |
|     | |                           | [      Move Up      ] |                     |
|     | |                           | [     Move Down     ] |                     |
|     | |                           |                       |                     |
|     | |                           |                       |                     |
|     | +---------------------------+                       |                     |
|     +-----------------------------------------------------+                     |
|                                                                                 |
|                               Back   [[ Next> ]]   Finish   [ Cancel ] [ Help ] |
+---------------------------------------------------------------------------------+

The Existing Library radio button would enable a noneditable combo box which would list all J2SE libraries in the system (similar to the Class Libraries section of the IDE’s Library Manager). The user can select any registered library.

The Custom Library radio button (selected by default) would enable a tabbed pane permitting selection of the JARs, sources, and Javadoc for a new library. The content of these panes is exactly as in the IDE’s Library Manager dialog (for Class Libraries).

Error conditions include:

  • Existing Library is selected, yet nothing is selected in the combo box (because there are no registered libraries).

  • Custom Library is selected, yet Library Classpath is empty.

New J2SE Library Descriptor Wizard—Name and Location

+---------------------------------------------------------------------------------+
| New J2SE Library Descriptor                                                     |
+---------------------------------------------------------------------------------+
| Name and Location                                                               |
| ------------------------------------------------------------------------------- |
|                                                                                 |
| Library _N_ame:   [mylibrary__________________________________________________] |
| _D_isplay Name:   [My Library_________________________________________________] |
|                                                                                 |
| _P_roject:        My Module                                                     |
| Pac_k_age:        [org.myorg.mymod___________________________________________v] |
|                                                                                 |
| _C_reated Files:  /mymod/src/org/myorg/mymod/mylibrary.xml                      |
|                   /mymod/release/libs/my-library.jar                            |
|                   /mymod/release/docs/my-library-api.zip                        |
|                                                                                 |
| _M_odified Files: /mymod/src/org/myorg/mymod/layer.xml                          |
|                   /mymod/src/org/myorg/mymod/Bundle.properties                  |
|                                                                                 |
|                             [ Back ]    Next>    [[Finish]] [ Cancel ] [ Help ] |
+---------------------------------------------------------------------------------+

Library Name is prepopulated with the code name of the library selected in the previous panel, if Existing Library was chosen; else initially empty.

Display Name duplicates the value of Library Name until explicitly edited.

Project is fixed by the wizard.

Package is a usual editable package chooser.

Created Files lists new files the wizard will create in a scrolling text area. libraryname.xml will be the actual library descriptor that is registered, with nbinst-protocol URLs for classpath, source, and javadoc volumes. The JAR files in the original library’s classpath will be copied to libs/ in the target cluster. Any source and/or Javadoc ZIPs will be copied to sources/ and docs/ (respectively). If source or Javadoc was originally defined as directories, the directories will be zipped up for inclusion in the module, with the basename of the archive being the library name.

Modified Files lists files the wizard will edit. The module’s XML layer will get one entry to register the library. The main localizing bundle will get one entry for the display name. Also, project.xml will be edited if necessary to add a non-compile-time dependency on the Project Libraries API module.

Error conditions include:

  • Library Name is empty.

  • Display Name is empty.

  • The default (anonymous) package is selected. This is forbidden for module code.

New Project Template—Wizard UI

Invoked as File | New File… and selecting category NetBeans Module Development and file type Project Template. HTML description of template:

Use this template to add a new template to the New Project wizard. This could be used to bundle sample applications that use a special technology, or to set up some complex project infrastructure (such as for a freeform project).

New Project Template Wizard—Select Project

+---------------------------------------------------------------------------------+
| New Project Template                                                            |
+---------------------------------------------------------------------------------+
| Select Project                                                                  |
| ------------------------------------------------------------------------------- |
|                                                                                 |
| _P_roject: [jini-sample________________________________________v] [Bro_w_se...] |
|                                                                                 |
|                                                                                 |
|                                                                                 |
|                                                                                 |
|                                                                                 |
|                                                                                 |
|                                                                                 |
|                                                                                 |
|                                                                                 |
|                                                                                 |
|                                                                                 |
|                               Back   [[ Next> ]]   Finish   [ Cancel ] [ Help ] |
+---------------------------------------------------------------------------------+

Project has a noneditable list of all currently open projects. The user may choose one of them, or click Browse… to open a regular project chooser dialog to select a non-open project. The project may be of any type.

Error conditions include:

  • No project is selected. (If the Project list was empty, and the user did not select a different project.)

  • The selected project contains external source roots, which are not supported by this wizard. (Technically: the selected project must have exactly one SourceGroup of TYPE_GENERIC, i.e. one folder in the Files tab.)

New Project Template Wizard—Name and Location

+---------------------------------------------------------------------------------+
| New Project Template                                                            |
+---------------------------------------------------------------------------------+
| Name and Location                                                               |
| ------------------------------------------------------------------------------- |
|                                                                                 |
| Template _N_ame:  [jini-sample________________________________________________] |
| _D_isplay Name:   [Jini Sample________________________________________________] |
| C_a_tegory:       [Samples/Standard______________