AMSS Lecture 3: Requirements Analysis

UML Use Case / Sequence Diagrams

Traian-Florin Șerbănuță

2025

Agenda

  1. What are requirements?

  2. Scenarios and use cases

  3. UML Use Case Diagrams

  4. Interactive Exercise 1: Identify actors and use cases

  5. UML Sequence Diagrams

  6. Interactive Exercise 2: Model an interaction

  7. Wrap-up and discussion

What Are Requirements?

Examples:

A course management system should:

functional

allow registered students to submit assignments online

non-functional

be able to accomodate up to 50k students

domain

comply with GDPR regulations

Why Requirements Matter

Without good requirements: models and implementations diverge from real needs.

Example (negative): Denver Airport Baggage System

Goal: Fully automated baggage handling system for all airlines

What Went Wrong:

Impact:

Key Lesson:

Clear, stable, and agreed-upon requirements are essential for complex system success.

From Requirements to Scenarios

Example Scenario:

A student logs into the portal, views enrolled courses, and submits a project file.

Use Cases

Notation: ovals (use cases), stick figures (actors), box (system boundary)

Example

Relationships Between Use Cases

Example

Interactive Exercise 1: Identify Actors and Use Cases

Scenario: A university online examination system.

Students can register for exams, view schedules, and submit answers online. Professors can create exams, publish grades, and review submissions. The system authenticates all users.

Tasks

  1. Identify at least 3 actors.
  2. Define 5–7 use cases.
  3. Sketch a use case diagram.

UML Sequence Diagrams

Visualize the sequence of interactions that fulfill a use case.

Elements

Example Sequence Diagram

Scenario: “User logs into the system”

Actors and objects:

Steps

  1. User enters credentials into a LoginInterface
  2. The LoginPage send verify credentials message to an AuthenticationService
  3. The AuthService sends check credentials to a Database
  4. The Database returns result
  5. The AuthService responds with success
  6. The Login Interface replies with success message

5a. The AuthService responds with error: Authentication Failed.

The Login Interface replies with success message

Example

Sequence diagram for user login
Sequence diagram for user login

Interactive Exercise 2: Model an Interaction

Scenario: “Customer places an order in an online shop.”

Actors and objects

Tasks

  1. Identify the main sequence of messages.
  2. Draw a sequence diagram (lifelines, messages, returns).
  3. Include one alternative path (e.g., payment failure).

Wrap-Up

Key Takeaways

Next Lecture

Some design patterns