• No results found

Object-Oriented Design

N/A
N/A
Protected

Academic year: 2021

Share "Object-Oriented Design"

Copied!
6
0
0

Loading.... (view fulltext now)

Full text

(1)

Object-Oriented Design

Peter Coad and Edward Yourdon

Technische Hochschule Darmstadt FACHBKREICH INFORMATIK B I B L I O T H E K Inventar-Nr.: ...A.Q.HA&. Sachg biete:.../??/.4 , Standort: YOURQDN PRESS PRENTICE HALL BUILDING ENGLEWOOD CLIFFS, NJ 07632

(2)

Contents

Preface Acknowledgments 0 Introduction 0.1 0.2 0.3 History

Method and Tool Future Advances 1 Improving Design 1.1 1.2 1.2.1 1.2.2 1.2.3 1.2.4 1.2.5 1.2.6 1.2.7 1.2.8 1.3 1.3.1 1.3.2 1.4 1.4.1 1.4.2 1.4.3 1.5 Basic Terminology

Principles for Managing Complexity Abstraction

Encapsulation Inheritance Association

Communication with Messages Pervading Methods of Organization Scale

Behavior Classification

OOD and the Impact of Prototyping Reasons for Prototyping

Advice^ for OOD Prototyping The Key Objectives of OOD Improve Productivity Increase Quality

Elevate Maintainability

Motivations and Benefits of OOD

2 Developing the Multilayer, Multicomponent Model

2.1 2.2 2.2.1 2.2.2 2.2.3 2.3 2.4 Discovering a Model A Continuum of Representation The Problem A Solution

Some Major Implications Five Layers, Five Activities

Four Components, Four Activities

xiii XV l 2 3 3 4 4 6 6 7 7 8 8 8 9 9 10 10 12 14 14 15 15 17 18 19 20 20 21 21 24 25 vii

(3)

viii Contents

2.5 Definitions and Notations 26 2.5.1 Definitions and Notations—Class-&-Object 26 2.5.2 Definitions and Notations—Structure 28 2.5.3 Definitions and Notations—Subject 30 2.5.4 Notation—Attribute (and Instance Connection) 32 2.5.5 Notation—Service (and Message Connection) 33 2.5.6 Notation—Summary 34

3 Designing the Problem Domain Component 36

3.1 What—Problem Domain Component 36 3.1.1 The Approach—What It Is Not 36 3.1.2 The Approach—What It Is 36 3.2 Why—Problem Domain Component 37 3.3 How—Problem Domain Component 37 3.3.1 Apply OOA 38 3.3.2 Use OOA Results—and Improve Them 38 3.3.3 Use OOA Results—and Add to Them 39 3.3.4 Example—Sensor Monitoring System 51 3.3.5 Example—OOA Tool™ 53

4 Designing the Human Interaction Component 56

4.1 What—Human Interaction Component 56 4.2 Why—Human Interaction Component 56 4.3 How—Human Interaction Component 57 4.3.1 Classify the Humans 57 4.3.2 Describe the Humans and Their Task Scenarios 58 4.3.3 Design the Command Hierarchy 60 4.3.4 Design the Detailed Interaction . 63 4.3.5 Continue to Prototype 64 4.3.6 Design the HIC Classes 65 4.3.7 Design, Accounting for Graphical User Interfaces 67 4.3.8 Example—Sensor Monitoring System 68 4.3.9 Example—OOA Tool™ 70

5 Designing the Task Management Component 72

5.1 What—Task Management Component 72 5.2 Why—Task Management Component 73 5.3 How—Task Management Component 73 5.3.1 Identify Event-Driven Tasks 74 5.3.2 Identify Clock-Driven Tasks 74

(4)

Contents ix

5.3.3 Identify priority Tasks and Critical Tasks 74 5.3.4 Identify a Coordinator 75 5.3.5 Challenge Each Task 75 5.3.6 Define Each Task 76 5.3.7 Example-Sensor Monitoring System 78 5.3.8 Example—OOA Tool™ 79

6 Designing the Data Management Component 80

6.1 What—Data Management Component 80 6.2 Why—Data Management Component 80 6.3 How—Data Management Component 80 6.3.1 Data Management Approaches 80 6.3.2 Assessing Data Management Tools 83 6.3.3 Designing the Data Management Component 84 6.3.4 Example—Sensor Monitoring System 86 6.3.5 Example—OOA Tool™ 87

7 Applying OOD with OOPLs (or Less Than an OOPL) 89

7.1 Being Utterly Pragmatic about Languages 89 7.2 The Language Impact on OO Development 89 7.3 Evaluating Language Syntax and Features 91 7.3.1 Evaluation Criteria 91 7.3.2 Syntax and Features—C++ and Object Pascal 92 7.3.3 Syntax and Features—Smalltalk and Objective-C 102 7.3.4 Syntax and Features—Eiffel 110 7.3.5 Syntax and Features—Ada 115 7.3.6 Syntax and Features—Procedural Languages 120 7.4 Selecting OOPLs 124 7.4.1 Which OOPLs Will Dominate? 124 7.4.2 Reusability across OOA to OOD to OOPLs 124 7.4.3 Class Library and Development Environment 124 7.4.4 Other Issues 125

8 Applying OOD Criteria 126

8.1 Introduction: What and Why 126 8.2 Coupling 129 8.2.1 Interaction Coupling 130 8.2.2 Inheritance Coupling 132 8.3 Cohesion 134 8.3.1 Service Cohesion 134

(5)

x Contents 8.3.2 8.3.3 8.4 8.4.1 8.4.2 8.4.3 8.4.5 8.5 8.5.1 8.5.2 8.5.3 8.5.4 8.5.5 8.5.6 8.5.7 8.5.8 8.5.9 8.5.10 8.6 Class Cohesion Generalization-Specialization Cohesion Reuse

Why Does It Matter

Why Aren't People Doing It? Levels of Reusability

Organizational Approaches to Reusability Additional Criteria

Clarity of Design

Generalization-Specialization Depth Keeping Objects and Classes Simple Keeping Protocols Simple

Keeping Services Simple Minimizing Design Volatility Minimizing Overall System Size Ability to "Evaluate by Scenario" Evaluation by "Critical Success Factors" Recognized Elegance in the Design Final Comments

9 Selecting CASE for OOD

9.1 9.2 9.2.1 9.2.2 9.2.3 9.2.4 9.2.5 9.2.6 9.3 9.4 Expanding Case

What's Needed for OOD Notation Layers Components Auto-Tracking Features Advanced Features Model Checks What's Available Additional Considerations

10 Getting Started with OOD

10.1 10.2 10.2.1 10.2.2

Another Silver Bullet?

Is this the Time to Start Using OOD? Is the Object-Oriented Paradigm Mature? Is There a Good Obiect-Oriented

134 135 136 136 137 138 140 141 141 143 144 145 145 146 146 147 147 148 148 149 149 149 150 150 150 151 151 151 152 153 154 154 154 156 156 Implementation Technology?

10.2.3 Is the Development Organization 157 Sophisticated Enough?

(6)

Contents xi

10.2.4 Is the Organization Building Systems That 158 Will Exploit Object-Oriented Techniques?

10.3 Revolution Versus Evolution 159 10.4 How to Get Started with OOD 160 10.5 Conclusion 161

A OOA/OOD Notation Summary 162 B OOA Strategy Summary 164 C OOD Strategy Summary 171 Bibliography 182 Index 190

References

Related documents

Výstupy z logistického auditu je možné použi ť pre návrh nápravných opatrení v oblasti riadenia podniku, prípadne ako podklad pre realizáciu navrhovaných zmien

Interestingly, they also reported that there is a negative effect of both defined benefit plan coverage and Social Security wealth on non-pension net worth but that the effects

Active Directory DirSync Windows Azure Active Directory OAuth2 SAML-P WS-Federation Metadata Graph API Office Activation Service Office 365 Admin. Portal Exchange Mailbox

Students, however, did not employ standardized tools to assess the health literacy of the patient or the patient’s knowledge of specific diseases, nor did they assess readability

They do so through images that fragment and glitch digital files; through formats that compel slowness and silence against the speed and noise of information flow; through

The lack of biological insecticides based on Metarhizium anisopliae (Metsch.) Sorokin registered in Italy for the control of the Red Palm Weevil (RPW), Rhynchophorus

refundable credit per taxpaying unit, a $500 credit per exemption, and a marginal tax rate of twenty—five percent applied to all of adjusted gross income with no deductions will

เพื่อเพิ่มความพึงพอใจของผูรับบริการกลุมเปาหมายจากการขอตออายุวีซาได อยางสะดวก รวดเร็วขึ้น ตัวชี้วัด , ผลผลิตและผลลัพธของโครงการ