Round Trip Workflows with ReqIF Files

Simulink® Requirements™ supports round trip workflows with ReqIF files. ReqIF is an open standard XML format developed for lossless exchange of requirements and their associated metadata​ between requirements management applications. You can import, edit, and export requirements by using ReqIF files.

Import Requirements from ReqIF Files

Many third-party requirements management applications can export and import requirements using the ReqIF™ format. You can import requirements from a ReqIF file as references to a third-party source, or as new requirement sets.

Third-party applications that use ReqIF with particular attribute mapping include:

  • Polarion™

  • PREEvision

  • IBM® Rational® DOORS®

  • IBM Rational DOORS Next Generation

Other third-party applications can use generic ReqIF mapping.

Third-party Specific Server Configuration

Polarion: When working with Polarion, modify the Polarion server configuration to use the actual server name in repo and base.url property values. Do not use localhost.

  1. Open the polarion.properties file found in the <polarion_installation>/polarion/configuration/ folder.

  2. Modify these lines:

    • repo=http://localhost:80/repo/

    • base.url=http://localhost:80/

    by replacing localhost with the externally known name for your server.

ReqIF Import Workflow

To import requirements from a ReqIF file:

  1. In the Requirements Editor, select File > Import.

  2. For Document type, select ReqIF file (*.reqif or *.reqifz).

  3. For Document location, select the ReqIF file location.

  4. Simulink Requirements detects the source tool of the ReqIF file. You can also manually select a Source tool, or select Generic if the source is unknown.

  5. Select the location for the destination requirement set.

  6. Select whether to allow updates to the imported requirements:

    1. If your requirements are maintained in an external tool, and you want to be able to update the imported requirement set with updated versions of the ReqIF file, select Allow updates from external source.

    2. To establish the Simulink Requirements set as the primary requirements artifact, do not select Allow updates from external source.

  7. Complete the import process by clicking Import.

Importing Multiple ReqIF Specifications

You can import multiple source specifications from ReqIF files. When you import ReqIF files that contain multiple source specifications, you can choose to:

  1. Select a single ReqIF source specification to import into a requirement set.

  2. Combine ReqIF source specifications into one requirement set. Each specification is imported into its own Import node. You can update each Import node independently.

  3. Import each ReqIF source specification into a separate requirement set. Instead of selecting a destination requirement set, you select a destination folder. The import operation creates multiple requirement set files in the destination folder.

If a ReqIF file contains a single specification, options 2 and 3 above are not available.

For large ReqIF files, import each source specification into a separate requirement set. This can help reduce file conflicts and simplify change tracking and differencing of individual requirement sets.

In ReqIF, a link is represented as a SpecRelation between two SpecObjects.. Select Import links to preserve links in the ReqIF file. Import links is enabled if the ReqIF file has SpecRelations between SpecObjects. After import, Simulink Requirements link set files contain links between requirements or external URLs.

If the ReqIF file does not define SpecRelations, the Import links option is disabled. Only valid links are imported. The link import operation depends on how you import the source specifications:

  1. Importing a single specification into a requirement set imports only the SpecRelations within the specification's SpecObjects. As a result, some links can be omitted.

  2. Combining ReqIF source specifications into one requirement set imports resolved links into one link set.

  3. Importing each ReqIF source specification into a separate requirement set imports resolved links are into separate linksets.

Customize Attribute Display

ReqIF represents a requirement as a SpecObject with user-defined attributes. You can customize how the Requirements Editor and Requirements Browser displays imported requirements data and properties.

To customize the display of imported requirements data, map the attributes of the SpecObject to either built-in or custom attributes of a requirement. You can save this mapping as an XML file for future use.

To modify the attribute mapping after you import, select the top-level Import node of the requirement set (denoted by ) and expand the Attribute Mapping pane. You can also load a previously saved attribute mapping by clicking Load mapping.

Edit Imported Content

Edit imported requirements content by using the editing capabilities of the Requirements Editor. You can unlock and edit a requirement's information such as its Description or Rationale. You can also define custom attributes on the requirement set and set values for those custom attributes on selected requirements.

Unlock and Edit Imported Requirements

Before you edit an imported requirement, you must unlock it. To unlock all requirements in the requirement set, select the top-level Import node of the requirement set and click Unlock all in the Requirement Interchange pane. To unlock individual requirements, navigate to the requirement and click Unlock in the Properties pane.

To add, remove, and edit custom attributes associated with the requirement set, navigate to the top-level node of the requirement set and use the actions available in the Custom Attribute Registries pane. Select an individual requirement and unlock it set custom attribute values.

Update Imported Requirements Content

If you selected Allow updates from external source during the Import operation, you can update your imported requirement sets with data from the source ReqIF file. Navigate to the top-level Import node of the requirement set and click Update. The Update operation overwrites all local modifications such as edits to unlocked requirements with values from the ReqIF source file. The Update operation preserves comments and local attributes.

Export Requirements Content

You can export a requirement set or an individual requirement and its child requirements to ReqIF files from Simulink Requirements. Navigate to the node that you want to export and select File > Export to ReqIF.

In the Export to ReqIF dialog box, you can select the export mapping and the output ReqIF file name and path. If you are exporting requirement artifacts that you previously imported (round trip workflow), it is recommended to use the same import settings for the Export operation.

The Export operation inverts the attribute mapping used by the Import operation. Any local custom attributes that you added to or defined in the Custom Attribute Registry are also included in the export mapping so that they are visible in external requirements management applications.

See Also

Related Topics