derive the model
Overview
With Next Design, you can not only handle various models related to design target software in one project, By creating a new model using an existing model as input, trace information between models is automatically recorded. It saves you the trouble of adding trace information later.
The design act of creating a new model using an existing model as input is called model derivation.
The metamodel definition and model derivation required for model derivation are described below in the following order.
- Derivation relationships are defined in the metamodel so that the [component structure model] can be derived from the [use case model].
- Derive [Component Configuration Model] from [Use Case Model]
- Add trace information between existing models
Derivation related definition image
Image of model derivation and tracing
1. Define derivation relationships in the metamodel
To derive the [Component Structure Model] from the [Use Case Model] and connect trace lines, define the derived relationships between the entities using the following procedure.
- Define the metamodel and view of the [component structure model] to be derived
- Define derived relationships between entities in the Use Case Model and the Component Structure Model
1.1 Define a metamodel and view of the component structure model
Define the meta model of [Component structure model] to be derived with reference to the following class diagram.
- Please refer to Quick Start > Profile Definition > Define Metamodel above for the procedure.
Define the diagram view of [Component structure model] referring to the following screen image.
- Please refer to Quick Start > Profile Definition > Define Diagram View above for the procedure.
1.2 Defining derived relationships between use cases and components
To define derived relationships between entities in the [Use Case Model] and [Component Structure Model], use class diagrams to define them in the same way as defining reference relationships.
Let's create a new class diagram that defines derived associations and only shows the associated entities.
Deriving Entity | Deriving Entity |
---|---|
component structure model > component | use case model > use case |
- Add a class diagram to your profile and enter the name Derived Association Diagram.
- Add existing entities with derived relationships from the Profile Navigator to the class diagram.
- Connect a derivation relationship from the deriving entity to the deriving entity.
- Now that you have defined derived relationships, you can derive models and add trace lines.
Now we have defined a [use case model] metamodel with [Actor] and [use case] as components, and a derivable [component structure model] metamodel.
2. Deriving components from use cases
To derive a new model using an existing model as input and trace information, proceed as follows:
- Display two models side by side
- Create a model using the components of the input model
2.1 Displaying two models side by side
add model
Add the [Component structure model] to be edited from the model navigator in the same way as when adding the [Use case model].
-
Model to be edited: [Modeling sample] > [Design model] > [Component structure model]
- First, right-click the project displayed at the top of the model navigator, and select Click [Add Model] > [Design Model] from the context menu to Add Design Model to the first level.
- Right-click the added [Design Model] and select Click [Add Model] > [Component Structure Model] from the context menu to Add a model to edit.
- When you add a model in the model navigator, it will be displayed in the main editor and ready for editing.
Show model in sub-editor
Follow the steps below to display the sub-editor on the right side of the screen and display the [UseCase Model] used as input for model creation.
- Click View > Pane > Sub Editor on the ribbon.
- Select [Input (Deep Blue)] from the [Switch display mode] pull-down list at the top of the sub-editor.
- Select [Use Case Model] from the pull-down list that is additionally displayed on the right.
- Click [View] > [Pane] > [Swap Left and Right] on the ribbon if you want to swap the positions of the sub-editor and the main editor.
2.2 Create a model using the components of the input model
To derive a new model with an existing model as input and trace information, drag and drop the components of the input model as follows.
- Move the pointer over an existing model component and drag the [+] icon that appears in the upper right corner.
- When dropped on a derived model, it adds a component to the model and also adds a trace line representing the derived relationship between the models.
3. Add trace information between existing models
To add trace information between existing model components, drop it on the [○] icon that appears in the upper left of the target model component.
- Move the pointer over an existing model component and drag the [+] icon that appears in the upper right corner.
- Drop it on the [○] icon displayed in the upper left of the existing model to which you want to associate the derived association.
- Dropping adds trace lines representing derived relationships between existing model components.