chap 5 oo analysis and design n.
Download
Skip this Video
Download Presentation
Chap 5. OO Analysis and Design

Loading in 2 Seconds...

play fullscreen
1 / 69

Chap 5. OO Analysis and Design - PowerPoint PPT Presentation


  • 115 Views
  • Uploaded on

OBJECT-ORIENTATION by Khoshafian and Abnous. Chap 5. OO Analysis and Design. 서울대학교 컴퓨터공학부 Internet Data Base Lab 교수 김형주. Overall Pictures of OO SW Design. Object-Oriented Software Engineering History of Software Engineering Designing Reusable Classes

loader
I am the owner, or an agent authorized to act on behalf of the owner, of the copyrighted work described.
capcha
Download Presentation

PowerPoint Slideshow about 'Chap 5. OO Analysis and Design' - rae-sears


Download Now An Image/Link below is provided (as is) to download presentation

Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author.While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server.


- - - - - - - - - - - - - - - - - - - - - - - - - - E N D - - - - - - - - - - - - - - - - - - - - - - - - - -
Presentation Transcript
chap 5 oo analysis and design

OBJECT-ORIENTATION by Khoshafian and Abnous

Chap 5. OO Analysis and Design

서울대학교 컴퓨터공학부

Internet Data Base Lab

교수 김형주

overall pictures of oo sw design
Overall Pictures of OO SW Design
  • Object-Oriented Software Engineering
    • History of Software Engineering
    • Designing Reusable Classes
  • Object-Oriented Analyasis / Design
    • E-R Modeling / Semantic Modeling
    • Booch method, Rambaugh OMT, Scheller-Mellor method
  • Unified Modeling Method (UML)
contents
Contents

1. Introduction

2. Inventions, Aspirations, and Requirements

3. Object-Oriented Analysis

4. Defining Object-Oriented Design

5. Semantic and ER Modeling

6. Overview of Existing Methodologies

Booch method

Rambaugh OMT method

Shlaer and Mellor method

1 introduction 1
1. Introduction(1)
  • The OO concepts are used throughout the process
    • requirement specification ( problem definition )
    • analysis ( what the product in question is )
    • design ( howit should be built )
introduction 2
Introduction (2)

Real-world Problem

Object-oriented

Concepts

ADT

OO

Analysis

OO

Design

Inheritance

Identity

Object-Oriented

Programming

modeling sw development processes 1
Modeling SW Development Processes (1)

Requirement

Specification

Waterfall model

(W. Royce, 1970)

Analysis

Design

Coding

Test

A “traditional” software

development “waterfall” process

Production

modeling sw development processes 2
Modeling SW Development Processes (2)
  • Dynamic and iterative nature of OO Development
    • In object-oriented development, third-party “components” or class hierarchies are integrated
    • Redesign an entirely new class structure, as the incrementally extended “forest” becomes unmanageable
slide8

The dynamic & iterative nature of OO development

Requirement

Innovations

in Analysis

and Design

Proposed

Enhancements

OO

Analysis

New

Possibilities

OO

Design

Performance

Issues

Client/Server

Computing

Component

Object Computing

OO

Programming

C

S

New Third-party

Class Hierarchies

New Technologies

object oriented analysis and design
Object-Oriented Analysis and Design
  • OOA(Object-Oriented Analysis) - what
    • is used to provide a detailed description of a system using object-oriented notation, concepts, and methodology
  • OOD(Object-Oriented Design) - how
    • concentrates on providing the blueprint for implementation
  • Design-before-Implementation Software Engineering
ooa ood methodologies 1
OOA/OOD Methodologies (1)
  • Shlaer and Mellor OOA/OOD
    • ( Shlaer and Mellor, 1988, 1992 )
  • Wirfs-Brock Responsibility Driven Design
    • ( Wirfs-Block and Wilkerson, 1989 )
  • Coad and Yourdon OOA/OOD
    • ( Coad and Yourdon, 1991a, 1991b )
  • Object Behavior Analysis
    • ( Rubin and Goldberg, 1992 )
  • Objectory method
    • ( Jacobson et al. , 1992 )
ooa ood methodologies 2
OOA/OOD Methodologies (2)
  • Martin and Odell OOA/OOD
    • ( Martin and Odell, 1993 )
  • Fusion
    • ( Coleman et al. , 1994 )
  • Booch OOA/OOD
    • ( Booch, 1994 )
  • Rumbaugh Object Modeling Technique(OMT)
    • ( Rumbaugh et al. , 1994 )
  • UML (Unified Modeling Language) !!!
contents1
Contents

1. Introduction

2. Inventions, Aspirations, and Requirements

3. Object-Oriented Analysis

4. Defining Object-Oriented Design

5. Semantic and ER Modeling

6. Overview of Existing Methodologies

Booch method

Rambaugh OMT method

Shlaer and Mellor method

2 inventions aspirations requirements
2. Inventions, Aspirations, Requirements
  • Requirements
    • The system functionality (by what, for whom)
    • The user/machine/system interaction
    • The environment (hw/sw platform, network)
  • The observation: Feedback and prototyping can further enhance and clarify the system
  • SW development methodology should consider the above issue!
contents2
Contents

1. Introduction

2. Inventions, Aspirations, and Requirements

3. Object-Oriented Analysis

4. Defining Object-Oriented Design

5. Semantic and ER Modeling

6. Overview of Existing Methodologies

Booch method

Rambaugh OMT method

Shlaer and Mellor method

3 object oriented analysis 1
3. Object-Oriented Analysis (1)
  • Booch’s definition of OOA
    • A method of analysis that examines requirements from the perspective of classes and objects found in the vocabulary of the problem domain.
  • What
    • What is the application being built from the end user’s perspective?
object oriented analysis 2
Object-Oriented Analysis (2)
  • Programmers must identify
    • Entities, relationships, and operations
    • Aspects of the behavior of entities
      • static( definition of classes )
      • dynamic( interaction between objects, state transition, and so on )
    • All operations
    • All constraints
  • Classification
    • The identification of the classes that contain objects similar to one another
object oriented analysis 3
Object-Oriented Analysis (3)

Major Findings of OOA

1. Objects and classes

2. Object attributes

3. Object and Class relationships

  • Inheritance Relationships
  • One-to-One, One-to-Many, Many-to-Many Relationships
slide18

Person

Multimedia

Employee

Student

Audio

Video

Images

SalesPerson

Secretary

Graphic

Raster

< A number of inheritance relationships >

slide19

< Entity Relationship for a workflow schema >

Created

By

1

N

WorkFlow

Person

N

1

Policy of

Department

1

N

Department

Has

Link

Has

Node

N

N

Node

Link

N/1

1/N

N

Destination

Node

1

Relationship

N

Source

Code

1

Entity

object oriented analysis 4

Boolean

Person

Integer

Object-Oriented Analysis (4)
  • Major Findings of OOA
  • 4. Operations on objects and classes

Workflow

CreatorWorkflow

< A number of methods associated

with the class Workflow >

NumberOfActiveWorkflows

ContainsNode (Rule)

object oriented analysis 41
Object-Oriented Analysis (4)

Major Findings of OOA

5. Dynamic concepts

  • State transition diagrams
  • Data flow diagrams
  • Timing diagrams

Immediate

State

Immediate

State

Event or

Action

Start

State

End or

Result State

State transition

slide22

Data flow

User

Data 1

Process

Process

2

1

Data 2

Storage 1

Data 3

Process

Process

4

3

Storage 2

contents3
Contents

1. Introduction

2. Inventions, Aspirations, and Requirements

3. Object-Oriented Analysis

4. Defining Object-Oriented Design

5. Semantic and ER Modeling

6. Overview of Existing Methodologies

Booch method

Rambaugh OMT method

Shlaer and Mellor method

4 defining object oriented design 1
4. Defining Object-Oriented Design (1)
  • Berard’s definition of OOD
    • Object-oriented design is that portion of the sw lifecycle that prepares definitions as to how the system will accomplish its requirements.
    • The models prepared in analysis are either refined, or transformed, into design models that depict the physical nature of the software product
defining object oriented design 2
Defining Object-Oriented Design (2)
  • The goal of design
    • To produce the structure of detailed implementation specifications
  • Analysis: requirement specification
  • Design: implementation specification
  • The design phase
    • A coarse-grained design phase
    • A more detailed design phase
coarse grained design 1
Coarse-Grained Design (1)
  • Coarse-Grained Approach
    • is to break the system into smaller subsystems
    • subsystems could be supported by different OOA and OOD methods
    • often this approach takes the form of layered systems & architectures with clean interfaces between the layers ( I.e., Client/Sever coarse-grained architecture )
coarse grained design 2
Coarse-Grained Design (2)
  • The coarse-grained design phase
    • Identification of all the subsystems or class categories involved in the system
    • Mapping of various categories onto different processes and processors
    • Identification of the third-party software modules
    • Identification of the various add-on components
slide28

Workflow Alerter, In/Out-Box, etc.

Workflow Design Tool

Workflow Activation Tool

Workflow Tracking-Status

Workflow Interpreter

Route Manager / Rule Manager

Workflow Tracking Manager

Workflow User & Group Manager

Workflow Administrator Manager

GUI & Enviroment

Client

Site

< Coarse-Grained

architecture of

a Workflow

system >

Workflow Manager Services

Server

Site

DBMS

E-Mail & Message

Service

more detailed design
More Detailed Design
  • More Detailed Design
    • the next phase of coarse-grained design, in the development life cycle
    • each class category is designed in great detail
    • all the structures, operations, object interactions, and dynamic concepts of the system are specified here
design specification more detailed
Design Specification (More Detailed)
  • Subsystems or class categories
  • Class definition
  • Class relationships
  • Object diagrams and object relationships
  • State transition
  • Timing diagrams
  • Designing algorithms
  • Physical compilation units
contents4
Contents

1. Introduction

2. Inventions, Aspirations, and Requirements

3. Object-Oriented Analysis

4. Defining Object-Oriented Design

5. Semantic and ER Modeling

6. Overview of Existing Methodologies

Booch method

Rambaugh OMT method

Shlaer and Mellor method

5 semantic and e r modeling
5. Semantic and E-R Modeling
  • DB structures and DB design
  • ER modeling has been one of the most successful paradigms for designing types and objects
  • ERs are the forerunners of more powerful semantic data models
  • ER model: Peter Chen, MIT, 1976
semantic data modeling
Semantic Data Modeling
  • Goal: to model the real world as closely as possible
    • do not incorporate behavioral abstraction
    • model structural abstraction
  • Design tools for DB
  • Assigning semantics: Node and Link
  • Many ideas from AI Knowledge Representation
  • Semantic Data Models
    • ER(Entity-Relationship) Model (Chen, 1976)
    • GSM(Generalized Semantic Model, (Hull and King, 1987)
    • And many many others
slide34

Link Types

in GSM

Node Types

in GSM

A Printable Entity Type

Single-valued Attribute

An AbstractEntity Type

Multivalued Attribute

Entity Types That Are

Subtypesof Other

Entity Types

IS-A Inheritance

Element of

Constructed Type

Aggregation(Cartesian Product)

Constructed Type

tuple

Grouping

Constructed Type

set

slide35

PersonAge

NAME

Name

last

first

Age

middle

Person

Address

Address

A GSM model for the

sales office automation

EmployeeSalary

Department

Salary

Department

Office

Worker

Account

Accounts

Orders

SalesPerson

Order

entity relationship modeling 1
Entity Relationship Modeling (1)
  • Entity type
    • A set of objects(entities)
  • Attributes
    • A function that can apply to an entity
  • Relationship
    • Cardinality (one-to-one, many-to-one, many-to-many)
entity relationship modeling 2
Entity Relationship Modeling (2)
  • Implementation steps of RDB applications

1. Identify Entity and Relationship of problem domain

(Drawing ER diagrams)

2. Merge views from different perspectives

3. Map an ER diagram onto a DB schema (a set of tables)

4. Physical design (Keys, Index, Replication)

slide38

Name

Salary

DeptName

Budget

< An ER model for the sales office automation >

Age

Works

In

M

N

SalesPerson

Department

N

Lives

At

1

1

1

Has

Accounts

Has

Orders

Address

Zip

N

N

StName

State

Account

Order

StNumber

City

contents5
Contents

1. Introduction

2. Inventions, Aspirations, and Requirements

3. Object-Oriented Analysis

4. Defining Object-Oriented Design

5. Semantic and ER Modeling

6. Overview of Existing Methodologies

Booch method

Rambaugh OMT method

Shlaer and Mellor method

6 overview of existing methodologies
6. Overview of Existing Methodologies
  • Issues for Selecting OO Methodology

1. Software Development Process

2. Notations and Diagrams

3. Application Domain (General vs Specific)

4. Language Constructs

5. Availability of Tools

booch s ooa and ood 1
Booch’s OOA and OOD (1)
  • Grady Booch, 1994
    • Rational Rose/C++
  • The major steps using Booch’s method
    • Requirement analysis (RA)
    • Domain analysis (OOA)
    • Design (OOD)
booch s ooa and ood 2
Booch’s OOA and OOD (2)
  • Requirement Analysis
    • use-case( Jacobson et al. , 1992 )
  • Domain Analysis
    • Identification of the classes
    • Identification of relationships
    • Identification of object diagrams
    • Identification of attributes and operations
    • Identify inheritance
use case
USE CASE
  • What is Use Case?
    • Scenario between System and User
    • Specific pattern of using System

Use Case Diagram

  • Use Case
    • Making new schedule
    • Notifying important promise
    • Showing someone’s public schedule

Show Calendar

for new schedule

Scheduler

Notify important promise

Actor1

Show someone’s

public schedule

Actor2

slide44

< Booch OOA: Identification of the classes in the problem >

Manager

Text

Candidate

Person

University

Employee

slide45

Booch OOA

< Class diagrams showing

attributes & inheritance >

< Identification of object diagrams >

1. Manager qualifies

2. Most people in department approve

3. An offer is made

Manager

Personnel

1

Propose

N

1

Text

3. Make Offer

(New Candidate)

1

Biography

Candidate

1

Interview

N

References

1

Universities

Attended

N

N

Interview

2. Linked by Most

(New Candidate)

Person

1. Qualifies

(New Candidate)

University

M

Manager

Department

Employee

slide46

Booch OOA

< Attributes & operations

for class Candidates >

<Inheritance hierarchies

in Booch notation>

Person

Candidate

Name : String

Date of Birth : Date

Social Security : String

Employee

Student

Corporate

Hiring Process

SalesPerson

Graduate

Candidate

HighestDegree( )

NumberOfYears

WorkExperience( )

Department

Hiring Process

Manager

Hiring Process

booch s ooa and ood 3
Booch’s OOA and OOD (3)
  • The steps of Booch’s OOD
    • Class categories for major components of the architecture
    • Detailed design
    • Processes and devices
    • Modules
slide48

Booch’s OOD

Some of the devices and processors

in a document imaging system

Class categories

for a workflow system

Workflow

User Interface

FAX

Station

OCR

Processing

Computer

Operating System

Graphical

Interface

Workflow

System

Scanner

Station

Database

Storage

Engine

Full-Text

Retrieval

Engine

Workflow

Database

Manager

Electronic

Messaging

Storage

Subsystem

the omt ooa and ood
The OMT OOA and OOD
  • James Rumbaugh, 1991
  • Object-Oriented Analysis (OOA)
    • Problem Statement
    • Object Model -- object diagram
    • Dynamic Model -- event trace, state transition diagram
    • Functional Model -- data flow diagram
  • Object-Oriented Design (OOD)
    • System Design
    • Object Design
object model
Object Model
  • The definitions of Object Model
    • the object model describes the structure of the objects in a system --- their identity, relationships to other objects, and attributes.
    • ( Rumbaugh et al. , 1991 )
  • Object Diagram
    • captures the notation for objects
omt object diagrams
OMT - Object Diagrams

Class with attributes

and operations

Relationships or

Associations

Inheritance/generalization

hierarchies

List Children

Spouse

Change Address

...

Class 1

Class 2

Person

Person

Name: String

Date of Birth: Date

...

Manager

Department

Student

Employee

Works-in

Employee

Department

Sales

Person

Marketing

Person

Salary

Role

Lives-in

Person

Address

omt dynamic model
OMT - Dynamic Model
  • Event & state
  • Event trace scenario
    • objects, messages
  • State transition diagram
    • events, states
slide53

Sends Resume

Acknowledge

Forwards Resume

Instructs Setting Up

Interview

Calls to Set Up Interview

Responds

Sets Up Interview

Schedule

Accepts Interview

Schedule

OMT dynamic modeling: Event trace

to set up interview for hiring a candidate

Hiring

Manager

Candidate

Secretary

slide54

OMT dynamic modeling: State transition

for trade transactions

Initiate:

Library

Search for

Company X

Recommend

Analyze

Next Potential

Trade

Search Library

on Company

Perform

Trade

Company

Initiate

Analysis

Perform

Stock/Company

Analysis

omt functional model 1
OMT - Functional Model(1)
  • Data flow diagram
  • Nodes in data flow diagrams
    • Processes
      • Accept values, process, output
    • Data stores
      • Store data
    • Actors
      • Objects producing and consuming values
omt functional model 2

FAX Image

Store

Document

Storage

OMT - Functional Model (2)

annotated

FAX

Machine

Process and

Digital FAX

Document

Annotate

FAX Image

Print

fax

fax

image

image

Data flow diagram in OMT

shlaer and mellor ooa and ood 1
Shlaer and Mellor OOA and OOD (1)
  • Lawrence Berkeley Lab., 1979
    • most applications used for the developed OOA method were for larger industrial-strength real-time applications
  • OOA
    • Partitioning into domains
    • Objects and Information Model
    • Lifecycles and State Transition Diagrams
    • Object Communication Diagram
    • Action Data Flow Diagrams
  • OOD
slide58

Shlaer & Mellor OOA: Partitioning into Domains

Hiring New

Employees

Requirement

Tracking

Department

and Employees’

Approval Process

Interview

Processing

Automated Hiring

User Interface

Server

Architecture

Document

Imaging

Networking

Programming

< Domain in an automated hiring process >

shlaer and mellor ooa and ood 2
Shlaer and Mellor OOA and OOD (2)
  • Objects and Information Model
    • Objects
      • Attributes
      • Identifiers cf.) key in RDB
    • Object relationships
      • One-to-one, one-to-many, many-to-many
      • Conditional, unconditional
      • Inheritance relationships
slide60

1. PERSON (P)

* SSN

* Name

- Date of Birth

- Nationality

- Marital Status

……....

(M:M)

C

(M:Mc)

C

C

(Mc:Mc)

  • Shlaer & Mellor OOA: Object and Information Model

(1:1)

C

(1:1c)

C

C

(1c:1c)

(1:M)

C

(1c:M)

C

(1:Mc)

C

C

(1c:Mc)

< “objects” &

their attributes >

< Relationship links

in Shlaer-Mellor >

< Inheritance

hierarchies in

Shlaer-Mellor >

shlaer and mellor ooa and ood 3
Shlaer and Mellor OOA and OOD (3)
  • Lifecycles and State Transition Diagrams
    • most objects in the real world go through life cycle
    • due to events that occur, objects can go one stage(state) to the other
slide62

Shlaer & Mellor OOA: State transition diagram

1.Waiting to

Receive FAX

Phone Rings

F1:FAX Answers Phone

2.Establishing

Protocol

Starting Transmission

F2:FAX Machine Is Receiving FAX Pages

State transition

for a FAX machine

in the Shlaer-Mellor

notation

3.Receiving

FAX

Terminating Transmission

F3:FAX Machine Indicates Completion of Transmission

4.Pringting

Report

shlaer and mellor ooa and ood 4
Shlaer and Mellor OOA and OOD (4)
  • Object Communication Diagram (OCD)
    • Capture the interaction between various objects and state models for the complete system
    • Abstraction of the whole system

State

model

External

Object

event

slide64

Errors

User at

Scan Station

OCR

System

OCR

Zoned Area

Scan

Image

Scan Completed

and Displayed

Scanning

Software

Start Scanning

Scanner

Recognized Text

Error Conditions

Display

Image

Create Text Window

Rescan

Window

Displaying

Image

Text Window

Display Text Stream

Shlaer & Mellor OOA: Object Communication Diagram

Object Communication for scanning and OCR-ing images

shlaer and mellor ooa and ood 5
Shlaer and Mellor OOA and OOD (5)
  • Action Data Flow Diagram
    • Processes
    • Stores
    • Data flows
    • Control flows
slide66

Date

Storage

Process 1

False

Process 1

Control

Data

Data

True

Process 2

Process 2

Process 3

Schlaer & Mellor OOA: Action Flow Diagrams

Shlaer-Mellor process model

supports control as well as data flow

shlaer and mellor ooa and ood 6
Shlaer and Mellor OOA and OOD (6)
  • OO Design in Shlaer and Mellor
    • Architecture domain
      • Supporting state machines and timers
    • A main program, the architecture classes, the application classes
    • Class diagrams, inheritance diagrams
    • Class structure charts
      • Internal structure of the code in the operations of the class
    • Dependency diagrams
      • Client/Server relationships between classes
    • OODLE(Object-Oriented Design Language)
contents6
Contents

1. Introduction

2. Inventions, Aspirations, and Requirements

3. Object-Oriented Analysis

4. Defining Object-Oriented Design

5. Semantic and ER Modeling

6. Overview of Existing Methodologies

Booch method

Rambaugh OMT method

Shlaer and Mellor method

summary
Summary
  • OOA/OOD Methodologies
  • OOA - what
  • OOD - how
  • Semantic data model
  • ER - popular in DB application design
  • Booch OOD
  • Rambaugh OMT
  • Shlaer-Mellor Method