Use Case Diagram – Unified Modeling
Language (UML)
• A Use Case Diagram is a type of Unified Modeling Language (UML)
diagram that represents the interaction between actors (users or
external systems) and a system under consideration to accomplish
specific goals.
• It provides a high-level view of the system’s functionality by
illustrating the various ways users can interact with it.
When to apply Use Case Diagram?
• When you need to gather and clarify user requirements, use case
diagrams help visualize how different users interact with the system.
• If you’re working with diverse groups, including non-technical
stakeholders, these diagrams provide a clear and simple way to convey
system functionality.
• During the system design phase, use case diagrams help outline user
interactions and plan features, ensuring that the design aligns with user
needs.
• When defining what is included in the system versus what is external,
use case diagrams help clarify these boundaries.
Use Case Diagram Notations
1. Actors
2. Use Cases
3. System Boundary
Actors
• Actors are external entities that interact with
the system. These can include users, other
systems, or hardware devices.
• In the context of a Use Case Diagram,
actors initiate use cases and receive the
outcomes.
• Proper identification and understanding of
actors are crucial for accurately modeling
system behavior.
Use Cases
• Use cases are like scenes in the play. They represent specific
things your system can do.
• In the online shopping system, examples of use cases could be
“Place Order,” “Track Delivery,” or “Update Product
Information”.
• Use cases are represented by ovals.
System Boundary
• The system boundary is a visual representation of the scope or
limits of the system you are modeling.
• It defines what is inside the system and what is outside. The
boundary helps to establish a clear distinction between the
elements that are part of the system and those that are external
to it.
• The system boundary is typically represented by a rectangular
box that surrounds all the use cases of the system.
How to draw a Use Case diagram in UML?
• Step 1: Identify Actors: Determine who or what interacts with the system. These are your actors.
They can be users, other systems, or external entities.
• Step 2: Identify Use Cases: Identify the main functionalities or actions the system must perform.
These are your use cases. Each use case should represent a specific piece of functionality.
• Step 3: Connect Actors and Use Cases: Draw lines (associations) between actors and the use cases
they are involved in. This represents the interactions between actors and the system.
• Step 4: Add System Boundary: Draw a box around the actors and use cases to represent the system
boundary. This defines the scope of your system.
• Step 5: Define Relationships: If certain use cases are related or if one use case is an extension of
another, you can indicate these relationships with appropriate notations.
• Step 6: Review and Refine: Step back and review your diagram. Ensure that it accurately represents
the interactions and relationships in your system. Refine as needed.
• Step 7: Validate: Share your use case diagram with stakeholders and gather feedback. Ensure that it
aligns with their understanding of the system’s functionality.
Use Case Diagram example(Online
Shopping System)
1. Actors:
• Customer
• Admin
2. Use Cases:
• Browse Products
• Add to Cart
• Checkout
• Manage Inventory (Admin)
3. Relations:
• The Customer can browse products, add to the
cart, and complete the checkout.
• The Admin can manage the inventory.