Child pages
  • MPS plugin for IntelliJ IDEA

Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

MPS 2.5 can be run as a plugin for IntelliJ IDEA enabling MPS-based DSLs to be used directly in a Java IDE and so interoperate tightly with other elements of the project. This document will guide you through the details of how to setup IntelliJ IDEA so that you can use the MPS plugin aongside your Java code.

Integration with the IntelliJ IDEA Project structure.

To enable the MPS features inside a particular java project module one can , you simply add the MPS facet to this the module using through the Module Settings dialog:

It is recommended We recommend you to create dedicated java source root for storing model files and specify it using a dedicated Java Source Root folder to store the MPS model files.  Use the Add Model Root button on the Soures tab of the MPS Facet configuration page:

Model root folders looks look just like any other source roots in IntelliJ IDEA, but in . In addition to the the regular source root content roots it is possible to create MPS models therein Model Roots:

It's necessary When creating a new model, you have to specify model its name and choose one of the available model kinds inside Kinds through the Create New Model dialog:

Model kind Each model Kind in this case means represents a preconfigured set of preconfigured used languages for new the model. Used languages list can be always modified This is a convenient shorthand that still allows you to tune the list of used languages manually at any time through the Model Properties dialog by pressing Alt+Enter on the model node inside the Project Tree:

Model Node in Project View represents MPS model contents and just like in MPS this it is similar to java package, so you can create model elements (Roots) inside it:

...