Docsity

Object-Oriented Design: Use Case Modeling and Identification, Slides of Object Oriented Analysis and Design

Partial preview of the text

Download Object-Oriented Design: Use Case Modeling and Identification and more Slides Object Oriented Analysis and Design in PDF only on Docsity!

1

Sharif University of Technology

Department of Computer Engineering

Object-Oriented Design Lecturer: Raman Ramsin^ Lecture 4: Use Case Modeling

Part 1

2

Object-Oriented Design – Lecture 4

Four Steps of requirements capture 1.^ Department of Computer Engineering

List candidate requirements

2.^

Understand system context

3.^

Capture functional requirements

4.^

Capture nonfunctional requirements

4

Object-Oriented Design – Lecture 4

Use case modeling^ „^ Department of Computer Engineering

Use case modeling typically proceeds as follows:^ ^

Find a candidate system boundary; Yougenerally begin with some initial estimate ofwhere the system boundary lies, to help youscope the modeling activity. Find the actors. Find the use cases:^ „^ specify the use case; „ identify key alternative flows.

^ Iterate until use cases, actors, and systemboundary are stable.

5

Object-Oriented Design – Lecture 4

Sharif University of Technology

Use Case Model^ „ Department of Computer Engineering

Four components:^

^

System boundary

  • a box drawn around the use

cases to denote the edge or boundary of the systembeing modeled. This is known as the

subject in

UML2. Actors

  • roles played by people or things that use the system. Use cases - things that the actors can do with the system. Relationships - meaningful relationships between

actors and use cases.

7

Object-Oriented Design – Lecture 4

Actors^ „^ Department of Computer Engineering

An actor specifies a role that some externalentity adopts when interacting with the systemdirectly. „^ It may represent a role played by:^ ^

a user

^ another system

^ a piece of hardware „^ In UML 2, actors may also represent othersubjects, giving a way to link different use casemodels.

8

Object-Oriented Design – Lecture 4

Actors: Notation^ „^ Department of Computer Engineering

Can be shown as a class icon stereotyped «actor» or as the "stickman" actor icon. „^

“Stick-man" form usually used to represent roles that are likely tobe played by people, and the class icon form to represent roleslikely to be played by other systems.

Accounting

10

Object-Oriented Design – Lecture 4

Identifying Actors^ „^ Department of Computer Engineering

Need to consider who or what uses the system, andwhat roles they play in their interactions with thesystem. „ Asking the following questions helps identify actors:^ ^

Who or what uses the system?

^ What roles do they play in the interaction?

^ Who installs the system?

^ Who or what starts and shuts down the system?

^ Who maintains the system?

^ What other systems interact with this system?

^ Who or what gets and provides information to the system?

^ Does anything happen at a fixed time?

11

Object-Oriented Design – Lecture 4

Actors: Specification „^ Department of Computer Engineering

Each actor needs a short name that makes sense fromthe business perspective. „^ Each actor must have a short description (one or twolines) that describes what this actor is from a businessperspective. Actor name:

Order Processing Clerk Description:

The Order Processing Clerk is responsible for processing sales orders, submitting reorder requests, requestingnecessary deposits from members and scheduling the delivery ofthe goods to members.

13

Object-Oriented Design – Lecture 4

Identifying Use Cases^ „^ Department of Computer Engineering

The best way of identifying use cases is to start withthe list of actors, and then consider how each actor isgoing to use the system. „^

Each use case must be given a short, descriptive namethat is a verb phrase. „^

Identifying use cases may also result in finding newactors.

14

Object-Oriented Design – Lecture 4

Identifying Use Cases: Helpful Questions^ „^ Department of Computer Engineering

The following list of questions helps identify the usecases:^ ^

What functions will a specific actor want from the system?

^ Does the system store and retrieve information? If so,which actors trigger this behavior?

^ What happens when the system changes state (e.g., systemstart and stop)? Are any actors notified?

^ Do any external events affect the system? What notifies thesystem about those events?

^ Does the system interact with any external system?

^ Does the system generate any reports?

16

Object-Oriented Design – Lecture 4

Project Glossary^ „^ Department of Computer Engineering

The glossary provides a dictionary of key businessterms and definitions. „^

It should be understandable by everyone in theproject, including all the stakeholders. „^

As well as defining key terms, the project glossarymust resolve synonyms and homonyms.

17

Object-Oriented Design – Lecture 4

Project Glossary: Example Department of Computer Engineering

19

Object-Oriented Design – Lecture 4

Use Case Specification: Template^ „^ Department of Computer Engineering

use case name - short, descriptive verb phrase in UpperCamelCase; „ use case ID - alternative routes are specified by using Dewey-decimalnumbering; „ brief description - a paragraph that captures the goal of the use case; „ actors involved in the use case;^ ^

primary actors - actually trigger the use case; secondary actors - interact with the use case after it has beentriggered. „^ preconditions - these are things that must be true before the use casecan execute - they are constraints on the state of the system; „^ main flow - the steps in the use case; „^ postconditions - things that must be true at the end of the use case; „^ alternative flows - a list of alternatives to the main flow.

20

Object-Oriented Design – Lecture 4

Use Case Specification: ExampleDepartment of Computer Engineering