DOCS

Maintaining Supertypes

By assigning an item type a supertype, the item type—or subtype—inherits the attributes of the supertype. Before you assign supertypes, take the following items into consideration:

  • Subtypes and supertypes do not have to belong to the same information model.
  • An item type can have more than one supertype and can itself be supertype of other item types. However, cycles are not permitted; the item type cannot be a subtype of an item type of which it also is a direct or indirect supertype.
  • The items of a subtype will become valid targets for all link and namespace relationships for which its supertypes are defined as valid target types.
  • An item type cannot be assigned as a supertype if any of the following conditions apply:
    • The item type is an extension type or a base type that has extension types.
    • The item type has an attribute that already is defined at the subtype (regardless of whether it is a base attribute or an extension of the attribute).
    • The item type has a base attribute and the subtype already inherits an extension of that attribute from another supertype.
    • The item type has an extension attribute and the subtype already inherits the base of that attribute or a different extension from another supertype, respectively.

You can resolve conflicting attribute assignments by detaching the attributes from their item types. To know more, see Detaching attributes from an item type.

To know more on the concepts of extension types and extension attributes, see the ASG-Rochade Concepts and Facilities.

Assigning supertypes to an item type

  1. Select the item type to which you want to assign the supertypes and then select ModelAdd Supertypes from the main menu.
  2. Or  

    Right-click the item type and then select Add Supertypes from the context menu.

    The Add Supertypes dialog box is displayed.

    This image shows the Add Supertypes dialog.
  3. In the Name specification field, enter a search term for the supertypes.
  4. From the Assigned to model (restricted) list, select the information model that contains the supertypes.
  5. Optional. Select the Restrict to abstract types check box to list only abstract types.
  6. Click Search to list the item types that match your search criteria.
  7. Select the supertypes that you want to assign and then click OK.
  8. The selected supertypes are assigned to the item type and the inherited attributes are listed in the type editor.

Detaching subtypes from item types

  1. Select the item types from which you want to detach the subtypes and then select ModelDetach Subtypes from the main menu.
  2. Or  

    Right-click the item types and then select Detach Subtypes from the context menu.

    The Detach Subtypes dialog box is displayed, listing the selected types and their subtypes.

    This image shows the Detach Subtypes dialog.
  3. Clear the check boxes of the item types for which you want to keep the inheritance relationships. This step is optional.
  4. Click OK to detach the selected subtypes.

Detaching supertypes from an item type

  1. Open the item type in the Type Editor.
  2. On the Type Structure panel, select the supertypes that you want to detach and then selected Detach from the context menu.
  3. This image shows the Type Structure panel.
    The supertypes are detached immediately.

    You also can use the Assign Supertypes dialog to modify supertype assignments. To know more, see Modifying the supertype assignments of an item type.

Modifying the supertype assignments of an item type

  1. Open the item type and then click the Maintain Supertypes icon in the local toolbar of the Type Editor.
  2. The Assign Supertypes dialog box is displayed.

    This image shows the Assign Supertypes dialog.
  3. To assign a supertype to the item type, enter the supertype’s name in the Enter the name of a type to add as supertype field and then click Add.
  4. Or  

    Click Select to open the Add Supertypes dialog and then proceed as described in step 2 in Assigning supertypes to an item type.

  5. To remove a supertype assignment, select the corresponding entry in the Supertypes list and then click Detach.
  6. When you have finished modifying the supertype assignments, click Finish to save your changes and close the Assign Supertypes dialog.
  7. Or  

    Click Cancel to close the dialog without saving the changes.