O'Reilly logo

Domain Specific Languages by Martin Fowler

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Chapter 55. Model-Aware Generation

Generate code with an explicit simulacrum of the semantic model of the DSL, so that the generated code has generic-specific separation.

image

When you generate code, you embed within that code the semantics of the DSL script. By using a Model-Aware Generation, you replicate some form of the Semantic Model in the generated code in order to preserve the separation of generic and specific code within the generated code.

55.1 How It Works

The most important aspect of Model-Aware Generation is that it preserves the principle of generic-specific separation. The actual form that the model takes in the generated code is ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required