Adding attributes to a use case

Because a use case is a stereotyped class, it can have attributes. No code is generated for these attributes.

About this task

IBM® Engineering Systems Design Rhapsody® does not display attributes in the use-case diagram. To access attributes for a use case, use the browser.

Adding a new attribute to a use case

Procedure

  1. Select the use case in the use-case diagram editor.
  2. Right-click the use case, and then select New Attribute. The Attribute window opens.
  3. Type a name for the attribute in the Name field.

    Use the L button next to the name field to assign a logical label.
  4. Select the Type, Visibility, and Multiplicity for the attribute.
  5. Type a description in the Description tab.
  6. Click OK.

Adding an existing attribute to a use case

Procedure

  1. In the browser, locate the class that contains the attribute.
  2. Click-and-drag the attribute to the use case in the browser. This action creates a separate copy of the attribute under the use case.

Results

Note: If you click-and-drag an attribute from one use case to another, the attribute is moved, not copied.