Moving Towards Specifications
• What functions will the new system provide?
– How will people interact with it?
– Describe functions from a user’s perspective
• UML Use Cases
– Used to show:
• the functions to be provided by the system
• which actors will use which functions
UML Use Case Diagrams
Capture the relationships between actors and use cases.
A use case diagram is a graphical depiction of a user’s possible interactions with a system. A use case diagram shows various use cases and different types of users the system has and will often be accompanied by other types of diagrams as well. The use cases are represented by either circles or ellipses. The actors are often shown as stick figures.
Application
While a use case itself might drill into a lot of detail about every possibility, a use-case diagram can help provide a higher-level view of the system. It has been said before that “Use case diagrams are the blueprints for your system”.[1]
Due to their simplistic nature, use case diagrams can be a good communication tool for stakeholders. The drawings attempt to mimic the real world and provide a view for the stakeholder to understand how the system is going to be designed. Siau and Lee conducted research to determine if there was a valid situation for use case diagrams at all or if they were unnecessary. What was found was that the use case diagrams conveyed the intent of the system in a more simplified manner to stakeholders and that they were “interpreted more completely than class diagrams”.
Identifying Actors
• Look for:
– the users who directly use the system
– also others who need services from the system
• To find actors that are people/roles ask:
– Who will be a primary user of the system? (primary actor)
– Who will need support from the system to do her daily tasks?
– Who will maintain, administrate, keep the system working?
(secondary actor)
– Who or what has an interest in the results that the system produces ?
• To find actors that are external systems ask:
– Which hardware devices does the system need?
– With which other systems does the system need to interact with?
Finding Use Cases
• For each actor, ask the following questions:
– Which functions does the actor require from the system?
– What does the actor need to do?
– Does the actor need to read, create, destroy, modify, or store some kinds of information in the system?
– Does the actor have to be notified about events in the system?
– Does the actor need to notify the system about something?
– What do those events require in terms of system functionality?
– Could the actor’s daily work be simplified or made more efficient through new functions provided by the system?
UML Sequence Diagrams
A sequence diagram or system sequence diagram (SSD) shows process interactions arranged in time sequence in the field of software engineering. It depicts the processes involved and the sequence of messages exchanged between the processes needed to carry out the functionality. Sequence diagrams are typically associated with use case realizations in the 4+1 architectural view model of the system under development. Sequence diagrams are sometimes called event diagrams or event scenarios.
For a particular scenario of a use case, the diagrams show the events that external actors generate, their order, and possible inter-system events. All systems are treated as a black box; the diagram places emphasis on events that cross the system boundary from actors to systems. A system sequence diagram should be done for the main success scenario of the use case, and frequent or complex alternative scenarios.