Supporting Module Types
IntelliJ Platform provides a set of standard module types. However, an application might need a module of a type that isn't supported yet. This tutorial shows how to register a new module type and link it to the project creation procedure and the UI.
The source code for the module
and project_wizard
code samples is used throughout this tutorial.
Pre-Requirements
Create an empty plugin project, see Creating a Plugin Project.
Register a New Module Type
Add a new com.intellij.moduleType
implementation with the IntelliJ Platform in the plugin.xml configuration file.
Implement ModuleType Interface
Create the DemoModuleType
implementation based on ModuleType
.
getNodeIcon()
should return module type specific icon.
Implement Custom Module Builder
Create DemoModuleBuilder
based on ModuleBuilder
.
Provide Custom Wizard Steps
Provide a straightforward implementation of UI components for the project creating stage. Create a generic DemoModuleWizardStep
based on ModuleWizardStep
Creating a Module of New Type
After compiling and running the plugin in a development instance, create a new project. Select . A new module type and its settings panel are available in the Project Wizard.