Editable Properties That Affect Object Deletion

Several options in the emxRequirements.properties file are checked to ensure that the object's parent/child relationships do not prevent it from being deleted.

This page discusses:

Deleting Requirement Objects

This process is followed when a user attempts to delete a requirement object:

  1. The object is disconnected from its current parent.
  2. A policy/state/access check ensures that the current user has delete privileges.
  3. A lock check determines whether the object is locked by another user. If so, it cannot be deleted.
  4. A parent relationship check ensures that this object is not linked to parent objects.

Only when all these conditions are satisfied can the object be deleted. In a case where multiple objects are selected for deletion, the Delete logic deletes as many objects as possible for which all the conditional checks are satisfied. A Delete Report specifies why any objects could not be deleted. In the case of a recursive delete, if the conditional check for any one object fails, then the entire transaction is rolled back. The branch (object and children) can be completely deleted only when the conditional checks are satisfied for all objects.

Checking Parent Relationships Before Deletion

The emxRequirements.properties file contains definitions of the parent relationships to check for each object type before deleting. The default values for each type, which can be modified, are:

emxRequirements.type_SoftwareRequirementSpecification.CheckParentRels=
emxRequirements.type_Requirement.CheckParentRels=relationship_SpecificationStructure
emxRequirements.type_Chapter.CheckParentRels=relationship_SpecificationStructure
emxRequirements.type_Comment.CheckParentRels=relationship_SpecificationStructure
emxRequirements.type_Decision.CheckParentRels=relationship_RequirementDecision

The following property specifies the parent relationship for requirement objects:

emxRequirements.type_Requirement.CheckParentRels=relationship_SpecificationStructure
This property setting indicates that a requirement can only be deleted when it has no parents pointing to it in a relationship_SpecificationStructure relationship (excluding its current parent displayed in the user interface).

When a requirement has a parent chapter, the requirement cannot be deleted from the Requirements list view. It can be deleted from the Specification structure display view because in that view its parent in relationship_SpecificationStructure is explicitly displayed; therefore, this parent is ignored in the parent check. In the Requirement list view, this parent check would fail. If this requirement has more than one parent chapter, the parent check would still fail even in the Specification structure display view unless its other parent chapters are also selected for deletion (using Delete > Selected Objects) or its other parents fall into the same branch selected for deletion (using Delete > Selected Object and Children).