NetbeansModule

Maven's model for the netbeans module descriptor.

<nbm
>
  <moduleType/>
  <codeNameBase/>
  <cluster/>
  <requiresRestart/>
  <manifest/>
  <homepageUrl/>
  <distributionUrl/>
  <author/>
  <licenseName/>
  <licenseFile/>
  <libraries/>
  <dependencies>
    <dependency
>
      <id/>
      <type/>
      <explicitValue/>
    </dependency>
  </dependencies>
  <nbmResources>
    <nbmResource
>
      <baseDirectory/>
      <relativeClusterPath/>
      <includes/>
      <excludes/>
    </nbmResource>
  </nbmResources>
</nbm>

nbm

Describes the layout, dependencies and packaging of a Netbeans module.

Element Description
moduleType

Type of the module. Possible values are

autoload - Such a module is automatically enabled when some other module requires it and automatically disabled otherwise.

eager - This module type gets automatically enabled when all it's dependencies are satisfied. Disabled otherwise.

normal - This is the default value. This kind of module is enabled/disabled manually by the user. It installs enabled.

codeNameBase Codenamebase of the module. Primary identification of the module. Usually the package name. Eg. "org.codehaus.mevenide.project". If not defined here, the default value is constructed from groupId and artifactId.
cluster Each modules should belong to a cluster. A cluster is a group of related modules. For individual modules it's not that important. Refer to netbeans.org documentation for more details.
requiresRestart Determines if the module requires restart of the IDE/platform upon installation.
manifest Location of the manifest file with Netbeans specific manifest entries.
homepageUrl Homepage URL of the module. Is accessible from Netbeans UI upon installation, should point to place with additional information about the functionality. If not defined, it defaults to POM's url element.
distributionUrl Http URL of the location where the module can be downloaded from the internet. This value put into the NBM and used when generating the Autoupdate Site. Should point directly to the NBM download.
author Author of the module. Is used when generating the NBM file.
licenseName Name of the license. If the user already agreed to the same license before, he/she won't be asked again to agree.
licenseFile Path to the license agreement file.
libraries groupId:artifactId of artifacts that shall become part of the module and be added on the classpath (ClassPath: manifest entry gets created and the jar is included in the nbm file)
dependencies List of module dependencies. The plugin will use it to Generate the OpenIDE-Module-Module-Dependencies manifest entry.
nbmResources List of resources that shall be also included into the Nbm file along with the module jar and library jars.

dependency

Element Description
id groupId:artifactId of the dependency defined in the POM (or a transitive dependency)
type Type of module dependency. 3 possible values allowed.

spec - specification dependency, module can only use public APIs in public packages. Works with the version defined and any later version.

impl - implementation dependency, module can use any class in the dependency module, but works with just the one version of the module.

loose - similar to spec, but isa very loose connection, no version is required, just the module presence.

explicitValue The plugin tries to resolve the correct module name and module specification/implementation version by examining the dependency jar's manifest. You can override this behaviour by explicitly defining the value here. For example org.openide.io/1 > 10.1 for a "spec" type of dependency.

nbmResource

Element Description
baseDirectory The base directory, all paths within the nbm file will be the same as paths within the base directory.
relativeClusterPath A relative path to be added to cluster root where the files will be copied to.
includes Include pattern, what shall be included in the nbm.
excludes Exclude pattern, what files within the basedir shall not be included.