Use Case Diagrams Week 1 Lab 1 What
Use Case Diagrams Week 1 – Lab 1
What is a Use Case Diagram? • Explains what the main functionality of the system is • Mainly cares for the system’s expected behavior (what) rather that how it is done!
Use Case Diagram: Components • 1) Actors • An actor specifies a role that some external entity adopts when interacting with the system directly. • It may represent a role played by: – a user – another system – a piece of hardware • Actors may be both at input and output ends of a use case
Use Case Diagram: Components • 2)Use Case • Describes all the services required or performed by the actor.
Example 1 • Construct a use case diagram for a library management system. The system is used by the librarian, the assistant librarian and the clients. • The librarian, can add books, delete books, add clients, delete clients, list books, list clients, check in/out books • The assistant librarian has all the functionality of the librarian except for add/delete for books and clients • Clients may only check in/out books
Example 1 - Continued • To find the actors Look for nouns • To find the user case Look for verbs
Example 1 • Construct a use case diagram for a library management system. The system is used by the librarian, the assistant librarian and the clients. • The librarian, can add books, delete books, add clients, delete clients, list books, list clients, check in/out books • The assistant librarian has all the functionality of the librarian except for add/delete for books and clients • Clients may only check in/out books
Example 2 • Construct a use case diagram for an online travel agency system. A new user can create a new profile with a username and a password. This profile can be changed at any time if the user wants. The user logs to the system using his/her username and password. • After logging into the system, the user inquires about different flights. The user can book, change or cancel a flight reservation. This includes choosing a payment method, and making a payment.
- Slides: 9