Writer Modes

Important Note: Writing data in DOORS is a non trivial task when it comes to determine exactly what should be written and how, notably when an update of existing data is to be performed.
Rather than using the model writer, you are now strongly encouraged to use the commands framework, which allows a Java programmer to control the update of DOORS data with fine grained interactions.

The writer has three modes:

For the following description, we consider the MDWorkbench model as reference. The following considered Item are designated by the Top Level Elements (TLE).

Replace

If a Folder or a Project does not exist in DOORS database, it is created. If a Module (Formal or Link) does not exist in the DOORS database, it is created with its content.

Exported Modules replace existings one in DOORS database if they already exist. In this use case, we considering that the MDWorkbench model has the "truth" at Modules level. It likes if we clear concerned Modules in order to replace them by the MDWorkbench model content (considering the TLE scope).

For a given concerned module:

Objects organization (hierarchy) is recreate from model base.
Projects, Folders and Modules which not exist in model are not deleted in DOORS database.

For example, if we write an MDWorkbench model in an empty DOORS database, at the end of the export, the DOORS database will reflect exactly the MDWorkbench model (according to the TLE).

Update

If a Folder or a Project does not exist in DOORS database, it is created. If a Module (Formal or Link) does not exist in the DOORS database, it is created with its content.

Exported Modules replace existings one in DOORS database if they already exist. In this use case, we considering that the MDWorkbench model has the "truth" at Modules level on the part it cover.

For a given concerned module:

Objects organization (hierarchy) is recreate from model base.
Projects, Folders and Modules which not exist in model are not deleted in DOORS database.

Add

If a Folder or a Project does not exist in DOORS database, it is created. If a Module (Formal or Link) does not exist in the DOORS database, it is created with its content.

Exported Modules replace existings one in DOORS database if they already exist only on the non coverd part of the DOORS database. In this use case, we considering that the MDWorkbench model has the "truth" at Modules level on the part DOORS database does not cover.

For a given concerned module:

Objects organization (hierarchy) is not recreate from model base.
Projects, Folders and Modules which not exist in model are not deleted in DOORS database.

Technical remarks

Project creation

DOORS does not allow two projects having the same name.
If the MDWorkbench model has a Project which already exist in DOORS, there is two possibilities:

N.B. the "com.sodius.mdw.doors.doors_base" property value is noted DOORS_BASE and designate an existing DOORS Project or Folder

N.B. the relative TLE qualified name is the bigger path we could create by following the owner relations of the project (recursively) in the consider Items defined by in the Top Level Elements

Module recognition

In DOORS, a Module is identify in two ways:

Object recognition

In DOORS, an Object is identify by its "Absolute Number" relative to a Module.
When writing a MDWorkbench model in DOORS database, be careful about these "Absolute Number".
If an Object has its "Absolute Number" equals to "0" in the MDWorkbench model, it can not be recognized, so it is always considered as a new Object.