7. Use Case Diagrams

The first diagram to look at is the Use Case diagram. The main ingredients for this type of diagram are use cases and actors, together they define the roles that users can play within a system. They are associated to the tasks, or use cases, they are involved in. It is often used in early stages of the design process to collect the intention requirements of a project.

If you are not well-acquainted with UML yet, remember that a use case is not just a bubble noted in the diagram. Along with this bubble, there should be a description of the use case, a typical scenario, exceptional cases, preconditions etc. These can either be expressed in external texts using regular text processing tools, requirements tools or file cards. It can be and is often refined using other diagrams like a sequence diagram or an activity diagram that explain its main scenarios. The basic description of a use case can also be inserted in the Documentation tab of the Details pane.

Figure 10.4. A Use Case diagram.

A Use Case diagram.

Extension points can be added to a use case via the extension point button in the Details pane or via the extension point rapid button.

7.1. Diagram Elements

  • Actors - Also referred to as Roles. Name and stereotype of an actor can be changed in its Properties tab.

  • Inheritance - Refinement relations between actors. This relation can carry a name and a stereotype.

  • Use cases - These can have Extension Points.

  • Extension Points - This defines a location where an extension can be added.

  • Associations - Between roles and use cases. It is useful to give associations speaking names.

  • Dependencies - Between use cases. Dependencies often have a stereotype to better define the role of the dependency. To select a stereotype, select the dependency from the diagram or the Navigation pane, then change the stereotype in the Properties tab. There are two special kinds of dependencies: <<extend>> and <<include>>, for which Poseidon offers own buttons (see below).

  • Extend relationship - A uni-directional relationship between two use cases. An extend relationship between use case B and use case A means that the behavior of B can be included in A.

  • Include relationship - A uni-directional relationship between two use cases. Such a relationship between use cases A and B means, that the behavior of B is always included in A.

  • System border - The system border is actually not implemented as model element in Poseidon for UML. You can simply draw a rectangle, send it to the background and use it as system border by putting all corresponding use cases inside the rectangle.

7.2. Toolbar

Select
Add or remove space between elements
Package
Subsystem
Actor
Actor as Classifier
Use Case
Generalization
Dependency
Association
Directed Association
Include
Extend
Collaboration
Classifier Role
Comment
Connect Comment to Element
Text
Ellipse
Rectangle
Polygon
Polyline
Repaint