Sept 200491.3913 Ron McFadyen1 Use Cases Introduced by Ivar Jacobson in 1986 literal translation from Swedish ”usage case” www.usecases.org - may be of.

Slides:



Advertisements
Similar presentations
CPSC 333: Foundations of Software EngineeringJ. Denzinger 2.2. Use Cases: Scenario based requirements modeling Recommended: Booch, Rumbaugh, Jacobson:
Advertisements

Use Case & Use Case Diagram
Actors and use cases Use-case diagram Brief notation Prioritization Fully dressed notation Requirements Functional requirements  Use-cases.
Use cases.
Extending the Requirements Model - techniques for detailing use cases
Information System Engineering
Muhammad Usman, Assistant Professor
Jan 15, Ron McFadyen1 Ch 9. Use-case model: drawing System Sequence Diagrams Iteration: a simple cash-only success scenario of Process Sale.
September Ron McFadyen1 design analysis implementation testing maintenance Waterfall Development Process Linear one phase is completed before.
January Ron McFadyen1 Use Cases in the UML Functionality under consideration is represented by use cases (named ellipses) enclosed in a box.
Sequence Diagram Objects are represented horizontally across the top of the diagram Each object has a lifeline some exist before and/or after some are.
Jan 16, Ron McFadyen1 Ch 9. Use-case model: drawing System Sequence Diagrams Iteration 1: a simple cash-only success scenario of Process Sale.
Jan Ron McFadyen1 Use Cases in the UML Functionality under consideration is represented by use cases (named ellipses) enclosed in a box Actors.
Jan Ron McFadyen1 Consider a simple cash-only Process Sale scenario 1. Customer arrives at a POS checkout with goods and/or services to purchase.
Design analysis implementation testing maintenance Waterfall Development Process Linear one phase is completed before the next begins in practice, must.
COMP 350: Object Oriented Analysis and Design Lecture 3 Case Studies, Inception & Use Cases References: Craig Larman Chapters 3-6.
January Ron McFadyen1 Ch 9. Use-case model: drawing System Sequence Diagrams Elaboration Iteration 1: a simple cash-only success scenario of.
Fall 2009ACS-3913 Ron McFadyen1 Use Cases Used to capture functional requirements – there are other requirements categories such as usability, reliability,
Use Cases & Requirements Analysis By: Mostafa Elbarbary.
Understanding Requirements
Copyright ©2004 Cezary Z Janikow 1 Use Cases n Within Requirements discipline/workflow n Verbal descriptions of important functional (behavioral, transactional,
Use Cases Introduced by Ivar Jacobson in 1986 literal translation from Swedish ”usage case” - may be of use to you in the future “blackbox”
Jan 8, Ron McFadyen1 Waterfall Spiral UP Case study UML Use Cases.
Jan R McFadyen1 Use Cases Widely used. Not just an OO technique. Diagramming defined in UML Each Use Case will meet one or more user goals;
Use Case Modeling. Kendall & Kendall© 2005 Pearson Prentice Hall18-2 Commonly Used UML Diagrams The most commonly used UML diagrams are: – Use case diagram,
Marcelo Santos – OOAD-CDT309, Spring 2008, IDE-MdH 1 Object-Oriented Analysis and Design - CDT309 Period 4, Spring 2008 More on use cases System sequence.
Sept Ron McFadyen1 Extend Relationship.
The first step in getting what you want is to decide what you want.
TK2023 Object-Oriented Software Engineering CHAPTER 6 SYSTEM SEQUENCE DIAGRAMS.
Software Engineering 1 Object-oriented Analysis and Design Chap 30 Relating Use Cases.
® IBM Software Group © 2006 IBM Corporation Rational Software France Object-Oriented Analysis and Design with UML2 and Rational Software Modeler 06. Requirements.
4 2009/10 Object Oriented Technology 1 Topic 4: The Object-Oriented Approach to Requirements Adopted from: Ch.7 The Object-Oriented Approach to Requirements.
Chapter 6 Use Cases. Use Cases: –Text stories Some “actor” using system to achieve a goal –Used to discover and record requirements –Serve as input to.
Sept Ron McFadyen1 Section 10.1 Domain Models Domain Model: a visual representation of conceptual classes or real-world objects in a domain.
SOFTWARE DESIGN AND ARCHITECTURE LECTURE 20. Review Software Requirements Requirements Engineering Process.
USE CASE Bayu Adhi Tama, MTI Faculty of Computer Science, University of Sriwijaya Slides are adapted from Petrus Mursanto
Review ♦ System sequence diagram ♦ Domain model
Faculty of Computer & Information
OOSE Use Case. Requirement Functional: –Features, capabilities, and security Non Functional: –Usability: Human factors, help, and documentation –Reliability:
Chapter 9 Applying UML and Patterns -Craig Larman
University of Toronto at Scarborough © Kersti Wain-Bantin CSCC40 Use Case 1 what are use cases? “A specification of sequences of actions, including variant.
1 Object-Oriented Modeling Using UML CS 3331 Section 2.4 Modeling Requirements with Use Cases.
Faculty of Applied Engineering and Urban Planning Software Engineering Department Software Engineering Lab Use Cases Faculty of Information system Technology.
1 Structuring Systems Requirements Use Case Description and Diagrams.
Sept Ron McFadyen1 Class Diagram Begins as a conceptual or analysis class model and evolves to a design class model Used throughout the development.
Business Analysis with For PG MDI, Gurgaon Kamna Malik, Ph.D.
Use Case Driven Analysis Requirements Use Case Use Case Description System Sequence Diagram Chapter 5.
Scenario A scenario is a sequence of steps describing an interaction between a user and a system. Use case is a set of scenarios tied together by a common.
January Ron McFadyen1 Domain Models Domain Model: a visual representation of conceptual classes or real-world objects in a domain of interest.
Sept Ron McFadyen1 Use Cases Introduced by Ivar Jacobson in 1986 literal translation from Swedish ”usage case” Used to capture and describe.
PRESENTATION ON USE CASE. Use Case Modeling Use case diagrams describe what a system does from the standpoint of an external observer. The emphasis is.
22 August, 2007Information System Design IT60105, Autumn 2007 Information System Design IT60105 Lecture 8 Use Case Diagrams.
IntellAgile Copyright © 2002 Craig Larman. All rights reserved. Writing Use Cases: Requirements in Context.
Understanding Requirements
Larman chapter 61 Use cases Larman chapter 6. 2 Fig. 6.1.
Chapter 6: Structuring Requirements: Use Case Description and Diagrams Object-Oriented Systems Analysis and Design Joey F. George, Dinesh Batra, Joseph.
Chapter 3: Software Design –Use case Diagram Nouf Alghanmi.
Requirements capture: Using UML Use Cases David Millard and Yvonne Howard {dem,
Sept Ron McFadyen1 Include Relationship UC1:Process Sale … Main Success Scenario … 7. Customer pays and System handles payment. … Extensions.
Jan Ron McFadyen1 Use Cases Used to capture functional requirements – there are other requirements categories such as usability, reliability,
Elaboration popo.
System Sequence Diagrams and Operation Contracts
Webapp Design with System Sequence Diagrams
UML Use Case Diagrams.
Writing Use Cases.
Start at 17th March 2012 end at 31th March 2012
SE-565 Software System Requirements IV. Use Cases
Use Case Modeling - techniques for detailing use cases
Using Use Case Diagrams
Use cases Dr. X.
Presentation transcript:

Sept Ron McFadyen1 Use Cases Introduced by Ivar Jacobson in 1986 literal translation from Swedish ”usage case” - may be of use to you in the future “blackbox” style is recommended - specify what the system must do, and not how it must do it. A project may begin with the definition of many “brief” or “casual” use case definitions. Later on, these can be become “fully dressed”

Sept Ron McFadyen2 Use Cases Widely used. Not just an OO technique. Each Use Case will meet one or more user goals Collectively, Use Cases represent the functionality required by a system. Stories of using a system to meet goals

Sept Ron McFadyen3 Use Cases Ch 6. Use Case example is very lengthy and fairly complete must read: pages 45-61, and sections 6.12, 6.13, 6.15 Ch 25 shows ways of managing Use Cases Ch 25. The Use Case has been broken down into multiple Use Cases that are related via > and > must read: sections 25.1, 25.2, 25.3, 25.5 Ch 13. Contracts Ch 9. System Sequence Diagrams SSDs show the events that actors generate. The system is a black box and so the diagram emphasizes the events the system must respond to.

Sept Ron McFadyen4 Use Cases in the UML Functionality under consideration is represented by use cases (named ellipses) enclosed in a box Actors are shown outside the box Actors are connected to use cases they use by associations Sept 21, 2003

Sept Ron McFadyen5 Actor Use Case Associations –Between Actors and Use Cases –Between Use Cases –Between Actors Use Cases in the UML

Sept Ron McFadyen6 Actors Actors represent the people or other systems that interact with the system. Each actor is drawn as a stick person with the name written underneath An actor represents a set of roles that users of a system may assume In a university registration system, we might have: StudentRegistration Manager Registration Clerk Department Chair

Sept Ron McFadyen7 Use Case Behaviour A Use Case describes a sequence of actions that a system performs to achieve an observable result of value to an actor (something meaningful to a user) A use case is drawn as an ellipse, with its name within or below the ellipse A Use Case Model comprises the individual use cases that describe the system A use case describe what a system does, not how it does it A use case must be written as a behaviour specification separately from the diagram (the written use case) We will see that other UML diagrams (e.g.statechart, sequence) can illustrate behavioural information about a use case A use case will be implemented as a computer program and the actors initiate execution (or instantiation) of a use case

Sept Ron McFadyen8 Use Case Example We might begin describing a registration system as: Register Manage courses Student Department Chair Generate report Registration Clerk Registration Between actors and use cases we draw associations (the lines) to indicate the use cases each actor can instantiate

Sept Ron McFadyen9 Figure 6.2 – a portion of Handle Returns Cashier Payment Authorization Service Process Rental NextGen … Process Sale Page gives a written description of the Process Sale use case

Sept Ron McFadyen10 Process Sale Use Case P. 50+ Primary Actor: Preconditions: describes a state the system must be in prior to the execution of the use case Postconditions: describes a state the system must be in after execution of the use case Main Success Scenario: Step by step description of the interaction between the actor and the executing use case Extensions or Alternate Flows Alternate ways steps could terminate At this point in time (Inception), processing a sale is described in one use case that contains a main success scenario and all possible alternative scenarios. Some components of the written use case:

Sept Ron McFadyen11 Process Sale Use Case P. 50+ Use Case UC1: Process Sale Primary Actor: Cashier … Preconditions: Cashier is identified and authenticated Postconditions: Sale is saved…Commissions recorded…Payment authorization approvals recorded Main Success Scenario: 1.Customer arrives at POS checkout with goods and/or services to purchase 2.Cashier starts a new sale 3.Cashier enters item identifier 4.System records sale line item and presents item description, price, and running total. Price calculated from a set of price rules. Cashier repeats steps 3-4 until indicates done. 5.System presents total with taxes calculated …

Sept Ron McFadyen12 Process Sale Use Case P. 50+ Cashier repeats steps 3-4 until indicates done. 5.System presents total with taxes calculated 6.Cashier tells customer the total, and asks for payment. 7.Customer pays and System handles payment 8.System logs completed sale and sends sale and payment information to the external Accounting System and Inventory System. 9.System presents receipt 10.Customer leaves with receipt and goods Extensions or Alternate Flows *a. At any time, the System fails: 1.Cashier restarts System, logs in, and requests recovery of prior sale 2.System reconstructs prior state. … …

Sept Ron McFadyen13 Process Sale Use Case P. 50+ Extensions or Alternate Flows *a. At any time, the System fails: 1.Cashier restarts System, logs in, and requests recovery of prior sale 2.System reconstructs prior state. … 3a. Invalid identifier: 1.System signals error and rejects entry 3b. There are multiple of same item category and tracking unique item identity not important (e.g. 5 packages of veggie burgers) 1. Cashier can enter item category identifier and the quantity … 4a. The system generated item price is not wanted … 1. Cashier enters override price. 2. System presents new price. … Identifies the step where this condition may arise. “*” means any step; “4” means at step 4; a letter following identifies a different exception

Sept Ron McFadyen14 Use Cases in the text Some places where use cases are specifically addressed: Chapter 9 introduces sequence diagrams, system events and system operations Chapter 13 adds contracts Chapter 25 discusses Include, Extend, and Generalization …

Sept Ron McFadyen15 Chapter 25 Relating Use Cases Include relationship If one use case (the base use case) is designed to use the functionality of another use case (the addition use case), there is an “include” dependency Consider that the base use case is executing. When it reaches the inclusion point, the addition use case is executed and when it finishes the base use case continues. Include is a way to factor commonality out of use cases to make the design more modular Suppose the Process Sale use case is designed to use the functionality of Handle Credit Payment and the Handle Check Payment use cases. The written Process Sale use case has in its Extensions section two inclusions:

Sept Ron McFadyen16 Include Relationship UC1:Process Sale … Main Success Scenario … 7. Customer pays and System handles payment. … Extensions or alternate flows: 7a. Paying by cash … 7b. Paying by credit: include Handle Credit Payment 7c. Paying by check: include Handle Check Payment

Sept Ron McFadyen17 Include Relationship In the UML diagram Process Sale Handle Check Payment Handle Credit Payment > Process Sale has a dependency on Handle Check Payment, and another dependency on Handle Credit Payment The dashed lines and the stick arrowhead are the correct way to depict dependencies

Sept Ron McFadyen18 Include Relationship Suppose a Purchase order system has two use cases Place Order and Track Order and both contain customer validation. Customer validation could be factored out, resulting in: Validate Customer > Track Order Place Order Customer

Sept Ron McFadyen19 More terminology Place Order and Track Order are called concrete use cases because they are initiated directly by an actor. Validate Customer is an abstract use case because it is never instantiated by itself; Validate Customer is only instantiated as part of another use case.

Sept Ron McFadyen20 Include Relationship Suppose ATM is a base use case and contains: 1.Show advertisement of the day 2.Include identify customer 3.Include validate account 4.… Validate Account > Identify customer Customer ATM session

Sept Ron McFadyen21 Generalization/Specialization Relationship Suppose there is more than one version of a use case, and that the different versions have some things in common and other things that differentiate them The general notation is Specialized use case name Generalized use case name

Sept Ron McFadyen22 Generalization/Specialization Relationship Example. Suppose we have a university registration system where people must be admitted to become students. Some potential students, who attended high school in the city, are already known to the university because they went through some prior screening processes. Admit new student Admit Student Admit HS student Admissions Clerk

Sept Ron McFadyen23 Generalization/Specialization Relationship Example. Suppose we have two ways to check someone’s identity: via a password or via a retinal scan Check Password Verify Identity Retinal Scan

Sept Ron McFadyen24 Generalization/Specialization of Actors Generalization can be applied to Actors. Example. Suppose for the department chair, who is a member of the faculty, there are some special duties FacultyChair Assign Grades Manage Sections Note that the Chair can do everything a faculty member can do, but also the Chair manages the sections of courses the department offers.

Sept Ron McFadyen25 Use Case Associations Between use case and actor –uses (unlabeled) Between use cases –include (dependency) –extend (dependency, condition) –generalization Between actors –generalization