Derived Classes and Derived Relationships Overview
A domain model can have an unlimited number of domain classes and domain relationships. These domain classes and domain relationships are referred to as elements when you create them by using the Domain-Specific Language Designer. You can derive any of these elements in the generated designer, as shown in the following illustration. You can use a derived type when the base is expected. Derived types can have not only method or property members but also additional custom behavior, which includes properties that are not in the base. The following illustration is based on the Library domain model. For more information, see Library.Dsl Overview.
Derived Elements and Derived Relationships
The illustration displays the following concepts:
The Person domain class.
The Book domain class.
The PersonChecksOutBook domain relationship.
The Student domain class.
The CirculationBook domain class.
The StudentChecksOutCirculationBook domain relationship.
The Student domain class is derived from the Person domain class.
The CirculationBook domain class is derived from the Book domain class.
The StudentChecksOutCirculationBook domain relationship is derived from PersonChecksOutBook domain relationship.
Note
The structure of the derived relationship must be consistent with the structure of the base relationship.
See Also
Concepts
Adding Validation to Domain-Specific Language Solutions
Generating Artifacts By Using Text Templates