+ All Categories
Home > Documents > 7. 2Object-Oriented Analysis and Design with the Unified Process Objectives Detailed...

7. 2Object-Oriented Analysis and Design with the Unified Process Objectives Detailed...

Date post: 13-Dec-2015
Category:
Upload: rudolph-perkins
View: 220 times
Download: 0 times
Share this document with a friend
Popular Tags:
31
7
Transcript
Page 1: 7. 2Object-Oriented Analysis and Design with the Unified Process Objectives  Detailed Object-Oriented Requirements Definitions  System Processes—A Use.

7

Page 2: 7. 2Object-Oriented Analysis and Design with the Unified Process Objectives  Detailed Object-Oriented Requirements Definitions  System Processes—A Use.

2Object-Oriented Analysis and Design with the Unified Process

Objectives

Detailed Object-Oriented Requirements Definitions

System Processes—A Use Case/Scenario View 

Identifying Inputs and Outputs—The System Sequence Diagram

Identifying Object Behavior—The Statechart Diagram

Integrating Object-Oriented Models

Page 3: 7. 2Object-Oriented Analysis and Design with the Unified Process Objectives  Detailed Object-Oriented Requirements Definitions  System Processes—A Use.

3Object-Oriented Analysis and Design with the Unified Process

Object-Oriented Requirements Definitions

Use case diagram: table of contents for business events System sequence diagrams (SSDs)

Define and order sequence of inputs and outputs Information flows referred to as messages

Class diagrams Identify real-world “things” Determine the structure of the programming classes

Statechart diagram describes collection of object states

Page 4: 7. 2Object-Oriented Analysis and Design with the Unified Process Objectives  Detailed Object-Oriented Requirements Definitions  System Processes—A Use.

4Object-Oriented Analysis and Design with the Unified Process

System Processes—A Use Case/Scenario View

Define use cases into two tiers:

Overview level derived from:

◘ Event table and use case diagrams

Detailed level derived from combination of:

◘ Use case description

◘ Activity diagram

◘ Sequence diagram

Page 5: 7. 2Object-Oriented Analysis and Design with the Unified Process Objectives  Detailed Object-Oriented Requirements Definitions  System Processes—A Use.

5Object-Oriented Analysis and Design with the Unified Process

Use Cases and Actors

Source Person or thing initiating the business event Must be external to the system

Actor Person or thing that touches the system Lies outside of automation boundary

Identifying actors at the right level of detail Assume actors (even non-human types) have hands Use case is a goal that the actor wants to achieve

Page 6: 7. 2Object-Oriented Analysis and Design with the Unified Process Objectives  Detailed Object-Oriented Requirements Definitions  System Processes—A Use.

6Object-Oriented Analysis and Design with the Unified Process

A Simple Use Case with an Actor

The Use Case Diagram

Page 7: 7. 2Object-Oriented Analysis and Design with the Unified Process Objectives  Detailed Object-Oriented Requirements Definitions  System Processes—A Use.

7Object-Oriented Analysis and Design with the Unified Process

A Use Case Diagram of the Order-Entry Subsystem for RMO, Showing a System Boundary

Page 8: 7. 2Object-Oriented Analysis and Design with the Unified Process Objectives  Detailed Object-Oriented Requirements Definitions  System Processes—A Use.

8Object-Oriented Analysis and Design with the Unified Process

A Use Case Diagram of the Customer Support System (by Subsystem)

Page 9: 7. 2Object-Oriented Analysis and Design with the Unified Process Objectives  Detailed Object-Oriented Requirements Definitions  System Processes—A Use.

9Object-Oriented Analysis and Design with the Unified Process

An Example of the Order-entry Subsystem With «Includes» Use Cases

Page 10: 7. 2Object-Oriented Analysis and Design with the Unified Process Objectives  Detailed Object-Oriented Requirements Definitions  System Processes—A Use.

10Object-Oriented Analysis and Design with the Unified Process

Brief Description of Create New Order Use Case

Developing a Use Case Diagram: (level 1-brief description)

Page 11: 7. 2Object-Oriented Analysis and Design with the Unified Process Objectives  Detailed Object-Oriented Requirements Definitions  System Processes—A Use.

11Object-Oriented Analysis and Design with the Unified Process

Intermediate Description of Telephone Order Scenario for Create New Order Use Case

Developing a Use Case Diagram: (level 2- Intermediate description)

Page 12: 7. 2Object-Oriented Analysis and Design with the Unified Process Objectives  Detailed Object-Oriented Requirements Definitions  System Processes—A Use.

12Object-Oriented Analysis and Design with the Unified Process

Fully Developed Description of Telephone Order Scenario for Create New Order Use Case

Developing a Use Case Diagram: (level 3- Fully developed description)

Page 13: 7. 2Object-Oriented Analysis and Design with the Unified Process Objectives  Detailed Object-Oriented Requirements Definitions  System Processes—A Use.

13Object-Oriented Analysis and Design with the Unified Process

Identifying Inputs and Outputs—the System Sequence Diagram

System sequence diagram (SSD)

Describes flow of information

Identifies interaction between actors and system

Message oriented

Page 14: 7. 2Object-Oriented Analysis and Design with the Unified Process Objectives  Detailed Object-Oriented Requirements Definitions  System Processes—A Use.

14Object-Oriented Analysis and Design with the Unified Process

SSD Notation

Actor “interacts” with the system via input/output SSDs use object notation

Box (rectangle) refers to individual object Name of the object underlined Messages sent/received by objects, not classes  

Lifeline Extension of object or actor for duration of the SSD Indicates sequence of the messages sent/received

Page 15: 7. 2Object-Oriented Analysis and Design with the Unified Process Objectives  Detailed Object-Oriented Requirements Definitions  System Processes—A Use.

Sequence Diagrams15

A Sequence Diagram

member:LibraryMember

book:Book:BookCopy

borrow(book)ok = mayBorrow()

[ok] borrow(member)setTaken(member)

X-Axis (objects)

Y-A

xis (tim

e)

ObjectLife Line

message

Activation box

condition

Page 16: 7. 2Object-Oriented Analysis and Design with the Unified Process Objectives  Detailed Object-Oriented Requirements Definitions  System Processes—A Use.

16Object-Oriented Analysis and Design with the Unified Process

Sample System Sequence Diagram

Page 17: 7. 2Object-Oriented Analysis and Design with the Unified Process Objectives  Detailed Object-Oriented Requirements Definitions  System Processes—A Use.

17Object-Oriented Analysis and Design with the Unified Process

Developing a System Sequence Diagram

Begin with detailed description of use case Fully developed form

Activity diagrams

(4) step process for turning activity diagram into SSD   [1] Identify the input messages

[2] Describe messages from external actor to system

[3] Identify/apply special conditions to input messages

[4] Identify and add the output return messages 

Page 18: 7. 2Object-Oriented Analysis and Design with the Unified Process Objectives  Detailed Object-Oriented Requirements Definitions  System Processes—A Use.

18Object-Oriented Analysis and Design with the Unified Process

Developing a System Sequence Diagram (continued)

Names of messages reflect services performed

Important principle for identifying data parameters Base the list on the class diagram

Attributes from the classes listed as parameters  

Iteratively define input/output parameters around workflows

Objective: discovery and understanding

Page 19: 7. 2Object-Oriented Analysis and Design with the Unified Process Objectives  Detailed Object-Oriented Requirements Definitions  System Processes—A Use.

19Object-Oriented Analysis and Design with the Unified Process

An SSD of the Simplified Telephone Order Scenario for the Create New Order Use Case

Page 20: 7. 2Object-Oriented Analysis and Design with the Unified Process Objectives  Detailed Object-Oriented Requirements Definitions  System Processes—A Use.

Sequence Diagrams20

Developing a System Sequence Diagram - Control information (con’t)

Condition syntax: ‘[‘ expression ’]’ message-label The message is sent only if the condition is true example:

Iteration syntax: * [ ‘[‘ expression ‘]’ ] message-label The message is sent many times to possibly

multiple receiver objects.

[ok] borrow(member)

Page 21: 7. 2Object-Oriented Analysis and Design with the Unified Process Objectives  Detailed Object-Oriented Requirements Definitions  System Processes—A Use.

Sequence Diagrams 21

Indicating selection and loops frame: box around part of a sequence diagram to indicate selection or loop

if -> (opt) [condition] if/else -> (alt) [condition], separated by horiz. dashed line loop -> (loop) [condition or items to loop over]

[balance <> 0]opt [balance < 100.00]

[balance >= 100.00]

alt

[balance < 0]loop

Page 22: 7. 2Object-Oriented Analysis and Design with the Unified Process Objectives  Detailed Object-Oriented Requirements Definitions  System Processes—A Use.

Sequence Diagrams 22

Exercise !!!Create a sequence diagram depicts on the following program:

Page 23: 7. 2Object-Oriented Analysis and Design with the Unified Process Objectives  Detailed Object-Oriented Requirements Definitions  System Processes—A Use.

23Object-Oriented Analysis and Design with the Unified Process

Identifying the Object Behaviorthe Statechart

Diagram A state in a statechart similar to status condition

Spans many business events

Developed for complex problem domain classes

Statechart diagram

Composed of ovals representing status of object

Arrows represent transitions  

Page 24: 7. 2Object-Oriented Analysis and Design with the Unified Process Objectives  Detailed Object-Oriented Requirements Definitions  System Processes—A Use.

24Object-Oriented Analysis and Design with the Unified Process

Identifying the Object Behaviorthe Statechart

Diagram (continued) Guidelines to help identify states

Check naming convention for status conditions Simple states reflect simple conditions such as “On” Complex states labeled with gerunds or verb phrases

◘ Example: “Being shipped” Active states usually not labeled with nouns Describe only states of being of the object itself Status conditions reported to management/customers

◘ Example: “Shipped”

Page 25: 7. 2Object-Oriented Analysis and Design with the Unified Process Objectives  Detailed Object-Oriented Requirements Definitions  System Processes—A Use.

25Object-Oriented Analysis and Design with the Unified Process

Rules for Developing Statecharts

[1] Select the classes that will require statecharts

[2] List all the status conditions for each group

[3] Specify transitions that cause object to leave the identified state

[4] Sequence state-transition combinations in correct order

Page 26: 7. 2Object-Oriented Analysis and Design with the Unified Process Objectives  Detailed Object-Oriented Requirements Definitions  System Processes—A Use.

26Object-Oriented Analysis and Design with the Unified Process

Rules for Developing Statecharts (continued)

[5] Identify concurrent paths.

[6] Look for additional transitions

[7] Expand each transition as appropriate

[8] Review and test each statechart

Page 27: 7. 2Object-Oriented Analysis and Design with the Unified Process Objectives  Detailed Object-Oriented Requirements Definitions  System Processes—A Use.

button1&2Pressed

button1&2Pressed

button1Pressed

button2Pressed

button2Pressed

button2Pressed

button1Pressed

button1&2Pressed IncrementMinutes

IncrementHours

BlinkHours

BlinkSeconds

BlinkMinutes

IncrementSeconds

StopBlinking

State Diagram : Example1StateInitial state

Final state

Transition

Event

Page 28: 7. 2Object-Oriented Analysis and Design with the Unified Process Objectives  Detailed Object-Oriented Requirements Definitions  System Processes—A Use.

State Diagram : Example2

28Object-Oriented Analysis and Design with the Unified Process

Page 29: 7. 2Object-Oriented Analysis and Design with the Unified Process Objectives  Detailed Object-Oriented Requirements Definitions  System Processes—A Use.

29Object-Oriented Analysis and Design with the Unified Process

Relationships among OO Requirements Models

OO requirements models

Page 30: 7. 2Object-Oriented Analysis and Design with the Unified Process Objectives  Detailed Object-Oriented Requirements Definitions  System Processes—A Use.

30Object-Oriented Analysis and Design with the Unified Process

Summary OOA family of models documents users’ needs and

defines system requirements

Use case detailed models (descriptive or activity)

Sequence diagrams (SSDs)

Domain model class diagrams

Statechart diagrams

Page 31: 7. 2Object-Oriented Analysis and Design with the Unified Process Objectives  Detailed Object-Oriented Requirements Definitions  System Processes—A Use.

31Object-Oriented Analysis and Design with the Unified Process

Summary (continued)

Use case: single system function responding to an event

Actors: human users or system interfaces that initiate system response

System function decomposed into workflows SSDs, domain models, statecharts emulate routines

and object interaction Software engineering terms signal transition into

design phase


Recommended