Because a use case is a stereotyped class, it can have
operations.
Procedure
- Select the use case in the use-case diagram
editor.
- Right-click the use case, and then select New
Operation. The Primitive Operation window
opens.
- Type a name for the operation in the Name field.
- If wanted, specify a stereotype.
- Select the visibility of the operation.
- Select a type for the operation in the Type field.
- Select the Return Type for
the operation.
- Specify the operation modifiers.
- Add any arguments using the Arguments section.
- Type a description in the Description tab.
- Select the Implementation tab.
- Type the implementation code for the operation
in the Implementation text box.
Note: Code is not generated for the contents of use cases.
This implementation is for descriptive purposes only.
- Click OK.