Defining CDM Scenario Types

A composite data model is structured in scenario types. Each entity of a composite data model belongs to a scenario type. The top-level blocks that can be found in a JDL file are application, scenarioType, entity and relationship.

Any JDL file that contains entities must also contain exactly one scenarioType block. In other words, the JDL file defines the scenario type.

By definition, the main JDL file contains an application block; it may also contain scenarioType, entity, and relationship blocks. The two supported use cases are:

  • The main JDL file only contains an application block.

  • The main JDL file contains an application block, a scenarioType block, and zero or more entity and relationship blocks.

Included JDL files must contain a scenarioType block and zero or more entity and relationship blocks.

The scenarioType block provides the name of the scenario type that is defined by the JDL file. There is no constraint between the name of the JDL file and the name of the scenario type. The name of the scenario type must be a valid identifier. The convention is to use Pascal case for scenario type names (that is, attached words with initial letters in uppercase, including the very first letter), as we do for examples for entities. The scenarioType block supports the @Description annotation.

@Description("Master data of the application")
scenarioType MasterData {
}