Prev | Next |
Developing Programming Languages
You can make use of a range of established programming languages in Enterprise Architect, but if these are not suitable to your needs you can develop your own. You would then apply it to your models through an MDG Technology that you might develop just for this purpose, or for broader purposes. After developing the language, you could also write MDA Transformation templates to convert a Platform Independent Model or a model in another language into a model for your new language, or vice-versa.
Access
Ribbon |
Code > Configure > Options > Edit Code Templates |
Keyboard Shortcuts |
|
Develop a Programming Language
Step |
Description |
See also |
---|---|---|
1 |
In the Code Template Editor, click on the and, on the 'Programming Languages Datatypes' dialog, click on the . Enter your new programming language name and define the datatypes for it. You cannot access the new language in the Code Template Editor until at least one datatype has been added to the language. |
Data Types |
2 |
After you have defined all the datatypes you need, click on the Code Template Editor, and start to edit or create the code templates for the new language. , select the language in the 'Language' field of the The code templates define how the system should perform:
|
Code Template Framework Code and Transform Templates Create Custom Templates Customize Base Templates |
3 |
If you prefer, you can also define source code options for your new language. These are additional settings for the language that are not provided by the data types or code templates, and that help define how the system handles that language when generating and reverse-engineering code. The code options are made available to your models only through an MDG Technology. |
Define Code Options |
4 |
Defining a grammar for your language is an optional step that provides two primary benefits:
To access the grammar editor select the 'Code > Schema > Grammars' ribbon option. |
Grammar Framework |
5 |
If you intend MDA transformations to be made to (or from) your new programming language, you can also edit and create transformation templates for it. The process of creating transformation templates is very similar to that for creating code templates. |
Edit Transformation Templates Write Transformations |
6 |
Having created the datatypes, code templates, code options, grammar and transformation templates for your new language, you can incorporate and distribute them in an MDG Technology. |
Create MDG Technologies Add Code Modules Add MDA Transforms Deploy An MDG Technology |