Freigeben über


Working with Domain Models Programmatically

This section shows you how to use custom code to access and modify a domain model, which is a graphical in-memory store representation of a domain-specific language. You create a domain model when you complete the Domain-Specific Language Designer Wizard.

When you create a domain model, the wizard generates code for your model. This code represents the elements in your model and their relationships. You can modify this code or create code on your own.

You should not modify generated classes directly because they are regenerated each time that you build a project. To make sure that your custom code does not get erased, you should override the class that you want to modify and make sure that the Generates Double Derived property is enabled. If this property is enabled, you can generate a partial class from a generated class and prevent your custom code from being erased.

In This Section