CS441 - Lecture 5 - Use Case Diagrams
CS441 - Lecture 5 - Use Case Diagrams
Resemble:
✔ Model processes (requirements).
✔ A temporal.
Different:
✔ Do not show flow of information.
✔ Do not follow a strict hierarchical structure.
✔ Do not model (explicitly) data repositories and sources.
SFDV3003 - System Analysis and Design
(12) Use Case Diagrams
ACTORS
Denoted by:
✔ stick figure
✔ role name underneath
Represent:
✔ roles that people have when interacting with the system.
✔ external systems or hardware that are essential to system
operation.
✔ other information systems or databases.
role-name
Examples:
✔ Employee, account holder, scheduling system, sales
database
SFDV3003 - System Analysis and Design
(12) Use Case Diagrams
USE CASES
Denoted by:
✔ an ellipse
✔ label inside or underneath
Represent:
+
✔ a discrete unit of system functionality. Label
✔ ‘...a sequence of actions that a system
performs to achieve an observable result of
value to an actor’.
[Source: Bennet et al., 2001]
Examples:
✔ Place an order, Rent a video, Check bank
balance, ...
SFDV3003 - System Analysis and Design
(12) Use Case Diagrams
ASSOCIATIONS
Denoted by:
✔ Solid line between actor and (associated) use case.
Represents:
✔ Relationship between actors and use cases (communication).
✔ Actor can be associated with more than one use case.
✔ Use case can be associated with more than one actor.
GENERALIZATION EXAMPLES
Two specializations of sales Two specializations of
person: deposit money:
SFDV3003 - System Analysis and Design
(12) Use Case Diagrams
Denoted by:
✔ a dashed arrow that points towards the base use case.
✔ <<extend>> label above arrow.
<<extend>> Cancel rental
Rent a Video
<<extend>>
EXTENSION POINTS
Used to clarify the circumstances and conditions that
trigger an extended use case.
Extensions defined in base use case directly under the use
case name.
Conditions are placed next to the relevant <<extend>>
association.
Extension points:
Problem with rental <<extend>>
Add new
Customer not a member member
SFDV3003 - System Analysis and Design
(12) Use Case Diagrams
Denoted by:
✔ a dashed arrow that points away from the base use case
towards mandatory activity.
✔ <<include>> label above arrow.
SYSTEM BOUNDARY
Represents boundary between the system and actors that
interact with the system.
Can organize related activities to simplify diagrams.
Optional.
Denoted by a rectangle box enclosing use cases.
Place an order
APPROACHES
Top-down:
✔ Find actors 🡪 find use cases 🡪 detail use cases
Bottom-up:
✔ create scenario 🡪 generalize scenario 🡪 organize use case model
TOP-DOWN APPROACH
1. Find actors and use cases.
✔ Who enters information and/or receives information?
✔ What other systems will interact with system?
Buy a product
Actor initiates the use case customer
Preconditions hungry or thirsty customer
Steps in the scenario First of all the customer inserts money into
the machine, selects one or more products,
and machine presents a selected product(s)
to the customer.
Postcondition product from the machine
Actor who benefits from the use case customer
SFDV3003 - System Analysis and Design
(12) Use Case Diagrams
Restock
Actor initiates the use case supplier
Preconditions the passage of the interval
Steps in the scenario supplier must do every time interval (say, one or two
weeks) are: Supplier unsecured the machine, opens
the front of the machine, and fills each brand's
compartment to capacity. (The supplier may fill each
brand according to consuming of article). Then he/
she close the front of the machine and secure it.
Postcondition supplier has a new set of potential sales
Actor who benefits from the use case supplier
SFDV3003 - System Analysis and Design
(12) Use Case Diagrams
THE "COLLECT MONEY" USE CASE
Collect Money
Actor initiates the use case collector
Preconditions the passage of the interval
Steps in the scenario collector must do are same as the steps of
supplier, but the collector don't deal with
products, he/ she deals with money. When
the time interval has passed this person
collects the necessary amount of money from
the machine.
Postcondition the money in hands of the collector
Actor who benefits from the use case collector
SFDV3003 - System Analysis and Design
(12) Use Case Diagrams
The Restock use case could be basis of another use case: "Restock
according to sales". Here supplier may fill up brands with new
products according of sale of those products. This is an extension of a
use case. After inclusion and extension the Restock use case can be:
SFDV3003 - System Analysis and Design
(12) Use Case Diagrams
SELF-SERVICE MACHINE
SFDV3003 - System Analysis and Design
(12) Use Case Diagrams
CASE STUDY
Courseware System Description
For this case study, the task is of constructing the design elements for a
system that can be used to manage courses and classes for an organization
that specializes in providing training. The name of the system is
Courseware System. The organization offers courses in a variety of areas
such as learning management techniques and understanding different
software languages and technologies. Each course is made up of a set of
topics. Tutors in the organization are assigned courses to teach according to
the area that they specialize in and their availability. The organization
publishes and maintains a calendar of the different courses and the assigns
tutors every year. There is a group of course administrators in the
organization who manage the courses including course content, assigning
courses to tutors, and defining the course schedule. The training
organization aims to use the Courseware System to get a better control and
visibility to the course management and to also streamline the process of
generating and managing schedules for different courses.
SFDV3003 - System Analysis and Design
(12) Use Case Diagrams
COURSEWARE OVERVIEW
The following terms and entities are specific to the system:
Courses and Topics that make up courses
Tutors that teach courses
Course Administrators who manage the assignment of
courses to tutors
Calendars and Course Schedules that are generated as a
result of the work performed by the course administrators
Students who refer to Calendars and Course Schedules to
decide which courses they wish to take up for study
SFDV3003 - System Analysis and Design
(12) Use Case Diagrams
Actors:
Tutor, Student, Course Administrator (main actor)
Questions