A module is a discrete unit of functionality which you can compile, run, test and debug independently.
Modules contain everything that is required for their specific tasks:
However, modules exist and are functional only in the context of a project. Depending on the logical and functional requirements to the project, you can create:
File > Project Structure > Module
Configuration information for a module is stored in a .iml module file. By default, such a file is located in the module's content root folder.
Development teams, normally, share the .iml module files through version control.
The information about modules the project includes is stored in %module_name%.iml files. Module files are created for each module.
Content root is a folder that contains all the files that make up your module.
Folders within a content root can be assigned to the following categories:
A facet represents certain configuration, specific for a particular framework/technology, associated with a moduel. A module can have multiple facets.
Module type | Description |
---|---|
Java Module | Encapsulates core functionality for building Java applications. The functionality of a Java module can be expanded by adding facets. |
Web Module | Provides facilities for developing web applications using programming languages other than Java, for example, PHP, or JavaScript, or markup languages. |
Plugin Module | Facilitates development of IntelliJ IDEA plugins. Supports IntelliJ IDEA SDK configuration and run configurations for running a dedicated IntelliJ IDEA instance for plugin debugging. |
J2ME Module | Provides facilities for developing J2ME mobile applications, including support for various Mobile JDK and J2ME-oriented run configurations. |
Flash Module | This module type is intended for developing Adobe Flash platform-targeted content (applications and libraries for web (Flash Player), desktop (Adobe AIR) and mobile devices (AIR mobile)). |
Android Module | Encapsulates core functionality for developing Android applications. |
Maven Module | Provides facilities for managing Maven projects, executing Maven goals, downloading artifacts. |
Grails Application | Provides facilities for Grails application development. |
Griffon Application | Provides facilities for Griffon application development. |
The following module types are available provided that the corresponding plugins are downloaded and enabled: | |
Ruby Module | Provides facilities for creating Ruby projects and Rails applications. |
Python Module | Provides facilities for Python, Django and Google App Engine development. |