Book a Demo
Prev Next

Redefine Stereotypes in Another Profile

If you want to redefine a stereotype in another profile, adding new tags and removing or modifying existing tags, while the stereotype behaves in all other ways as if it is the original stereotype, you can use a Redefines relationship as described here.

Apply a Redefines Relationship

Step

Action

1

Create a Stereotype element with the same name as the fully-qualified name of the stereotype that you are redefining. See 'TOGAF::Principle' in the example.

Set this stereotype element to 'Abstract'.

2

Create a Stereotype element with the same name, not fully-qualified. See 'Principle' in the example.

Draw a Redefines relationship from the redefining stereotype to the redefined stereotype.

3

To:

  • Remove a tag from the redefined stereotype, drop a 'Removed Attribute' attribute from the 'Profile' page of the diagram toolbox onto the redefining stereotype.  Name the attribute using the same name as the tag you wish to remove.  This creates a new attribute with the stereotype <<removed>>, which prevents inheritance of the tagged value from the original stereotype; see 'Implications' in the example
    A 'Principle' element created using our profile will act in all ways as a TOGAF Principle element, but will not have the usual 'Implications' tag
  • Add a new tag to the redefined stereotype, simply give the redefining stereotype the tag; in the example, the new 'Application' tag is not provided by the TOGAF profile but will appear as if it were
  • Modify an existing Tagged Value Type in the redefined stereotype, give the redefining stereotype a tag with the same name as the tag you wish to modify, but with a different type; in the example, 'Type' is an enumeration from the TOGAF profile, but we have given it a modified set of enumeration literals, and 'Metric' is a plain text tag in the TOGAF profile, but we have redefined it as a RefGUIDList tag that references a new 'Metric' stereotype

4

After the profile has been saved and deployed in an MDG Technology, the user can, by setting the technology to 'Active', specify that any redefined elements created should be created using the redefinitions in the active technology.

Example Diagram

Redefines generalization extending a non-UML type in Sparx Systems Enterprise Architect.