This International Student Edition is for use outside of the U.S. NINTH EDITION Software Engineering A PRACTITIONER'S APPROACH ROGER S.PRESSMAN 筋 BRUCE R.MAXIM
Software Engineering A PRACTITIONER’S APPROACH NINTH EDITION This International Student Edition is for use outside of the U.S. ROGER S. PRESSMAN BRUCE R. MAXIM
CONTENTS AT A GLANCE CHAPTER 1 Software and Software Engineering 1 PART ONE THE SOFTWARE PROCESS 19 CHAPTER 2 Process Models 20 CHAPTER 3 Agility and Process 37 CHAPTER 4 Recommended Process Model 54 CHAPTER 5 Human Aspects of Software Engineering 74 PART TWO MODELING 83 CHAPTER 6 Principles That Guide Practice 84 CHAPTER 7 Understanding Requirements 102 CHAPTER 8 Requirements Modeling-A Recommended Approach 126 CHAPTER 9 Desian Concepts 156 CHAPTER 10 Architectural Design-A Recommended Approach 181 CHAPTER 11 Component-Level Design 206 CHAPTER 12 User Experience Design 233 CHAPTER 13 Design for Mobility 264 CHAPTER 14 Pattern-Based Design 289 PART THREE QUALITY AND SECURITY 309 CHAPTER 15 Quality Concepts 310 CHAPTER 16 Reviews-A Recommended Approach 325 CHAPTER 17 Software Quality Assurance 339 CHAPTER 18 Software Security Engineering 356 CHAPTER 19 Software Testing-Component Level 372 CHAPTER 20 Software Testing-Integration Level 395 CHAPTER 21 Software Testing-Specialized Testing for Mobility 412 CHAPTER 22 Software Configuration Management 437 CHAPTER 23 Software Metrics and Analytics 460 5011T
vii CHAPTER 1 Software and Software Engineering 1 PART ONE THE SOFTWARE PROCESS 19 CHAPTER 2 Process Models 20 CHAPTER 3 Agility and Process 37 CHAPTER 4 Recommended Process Model 54 CHAPTER 5 Human Aspects of Software Engineering 74 PART TWO MODELING 83 CHAPTER 6 Principles That Guide Practice 84 CHAPTER 7 Understanding Requirements 102 CHAPTER 8 Requirements Modeling—A Recommended Approach 126 CHAPTER 9 Design Concepts 156 CHAPTER 10 Architectural Design—A Recommended Approach 181 CHAPTER 11 Component-Level Design 206 CHAPTER 12 User Experience Design 233 CHAPTER 13 Design for Mobility 264 CHAPTER 14 Pattern-Based Design 289 PART THREE QUALITY AND SECURITY 309 CHAPTER 15 Quality Concepts 310 CHAPTER 16 Reviews—A Recommended Approach 325 CHAPTER 17 Software Quality Assurance 339 CHAPTER 18 Software Security Engineering 356 CHAPTER 19 Software Testing—Component Level 372 CHAPTER 20 Software Testing—Integration Level 395 CHAPTER 21 Software Testing—Specialized Testing for Mobility 412 CHAPTER 22 Software Configuration Management 437 CHAPTER 23 Software Metrics and Analytics 460 Contents at a Glance
CONTENTS AT A GLANCE PART FOUR MANAGING SOFTWARE PROJECTS 489 CHAPTER 24 Project Management Concepts 490 CHAPTER 25 Creating a Viable Software Plan 504 CHAPTER 26 Risk Management 532 CHAPTER 27 A Strategy for Software Support 549 PART FIVE ADVANCED TOPICS 567 CHAPTER 28 Software Process Improvement 568 CHAPTER 29 Emerging Trends in Software Engineering 583 CHAPTER 30 Concluding Comments 602 APPENDIX 1 An Introduction to UML 611 APPENDIX 2 Data Science for Software Engineers 629 REFERENCES 639 INDEX 659
viii CONTENTS AT A GLANCE PART FOUR MANAGING SOFTWARE PROJECTS 489 CHAPTER 24 Project Management Concepts 490 CHAPTER 25 Creating a Viable Software Plan 504 CHAPTER 26 Risk Management 532 CHAPTER 27 A Strategy for Software Support 549 PART FIVE ADVANCED TOPICS 567 CHAPTER 28 Software Process Improvement 568 CHAPTER 29 Emerging Trends in Software Engineering 583 CHAPTER 30 Concluding Comments 602 APPENDIX 1 An Introduction to UML 611 APPENDIX 2 Data Science for Software Engineers 629 REFERENCES 639 INDEX 659
TABLE OF CONTENTS Preface xxvii CHAPTER 1 SOFTWARE AND SOFTWARE ENGINEERING 1 1.1 The Nature of Software 4 1.1.1 Defining Software 5 112 Software Application Domains 7 1.13 Legacy Software 8 1.2 Defining the Discipline 8 1.3 The Software Process 9 13.1 The Process Framework 10 1.3.2 Umbrella Activities 11 1.3.3 Process Adaptation 11 1.4 Software Engineering Practice 12 141 he Ess 1.4.2 1.5 How It All Starts 15 1.6 Summary 17 PART ONE THE SOFTWARE PROCESS 19 CHAPTER 2 PROCESS MODELS 20 2.1 A Generic Process Model 21 2.2 Defining a Framework Activity 23 2.3 Identifying a Task Set 23 2.4 Process Assessment and Improvement 24 2.5 Prescriptive Process Models 25 2.5.1 The Waterfall Model 25 2.5. Prototyping Process Model 26 2.5.3 Evolutionary Process Model 29 254 Unified Process Model 31 2.6 Product and Process 33 2.7 Summary 35
ix Table of Contents Preface xxvii CHAPTER 1 SOFTWARE AND SOFTWARE ENGINEERING 1 1.1 The Nature of Software 4 1.1.1 Defining Software 5 1.1.2 Software Application Domains 7 1.1.3 Legacy Software 8 1.2 Defining the Discipline 8 1.3 The Software Process 9 1.3.1 The Process Framework 10 1.3.2 Umbrella Activities 11 1.3.3 Process Adaptation 11 1.4 Software Engineering Practice 12 1.4.1 The Essence of Practice 12 1.4.2 General Principles 14 1.5 How It All Starts 15 1.6 Summary 17 PART ONE THE SOFTWARE PROCESS 19 CHAPTER 2 PROCESS MODELS 20 2.1 A Generic Process Model 21 2.2 Defining a Framework Activity 23 2.3 Identifying a Task Set 23 2.4 Process Assessment and Improvement 24 2.5 Prescriptive Process Models 25 2.5.1 The Waterfall Model 25 2.5.2 Prototyping Process Model 26 2.5.3 Evolutionary Process Model 29 2.5.4 Unified Process Model 31 2.6 Product and Process 33 2.7 Summary 35
TABLE OF CONTENTS CHAPTER 3 AGILITY AND PROCESS 37 3.1 What Is Agility?38 3.2 Agility and the Cost of Change 39 3.3 What Is an Agile Process?40 3.3.1 Agility Principles 40 3.3.2 The Politics of Agile Development 41 3.4 Scrum 42 3.4. Scrum Teams and Artifacts 43 342 Sprint Planning Meeting 44 3.43 Daily Scrum Meeting 44 3.4.4 Sprint Review Meeting 5 3.4.5 Sprint Retrospective 45 3.5 The XP Framework 46 3.5.2 Kanban 48 3.5.3 DevOps 50 3.6 Summary 51 CHAPTER 4 RECOMMENDED PROCESS MODEL 54 4.1 Requirements Definition 57 4.2 Preliminary Architectural Design 59 4.3 Resource Estimation 60 4.4 First Prototype Construction 61 4.5 Prototype Evaluation 64 4.6 Go.No-Go Decision 65 4.7 Prototype Evolution 67 471 New Prototype Scope 67 4.7.2 Constructing New Prototypes 68 4.7.3 Testing New Prototypes 68 4.8 Prototype Release 68 4.9 Maintain Release Software 69 4.10 Summary 72 CHAPTER 5 HUMAN ASPECTS OF SOFTWARE ENGINEERING 74 5.1 Characteristics of a Software Engineer 75 5.2 The Psychology of Software Engineering 75
x TABLE OF CONTENTS CHAPTER 3 AGILITY AND PROCESS 37 3.1 What Is Agility? 38 3.2 Agility and the Cost of Change 39 3.3 What Is an Agile Process? 40 3.3.1 Agility Principles 40 3.3.2 The Politics of Agile Development 41 3.4 Scrum 42 3.4.1 Scrum Teams and Artifacts 43 3.4.2 Sprint Planning Meeting 44 3.4.3 Daily Scrum Meeting 44 3.4.4 Sprint Review Meeting 45 3.4.5 Sprint Retrospective 45 3.5 Other Agile Frameworks 46 3.5.1 The XP Framework 46 3.5.2 Kanban 48 3.5.3 DevOps 50 3.6 Summary 51 CHAPTER 4 RECOMMENDED PROCESS MODEL 54 4.1 Requirements Definition 57 4.2 Preliminary Architectural Design 59 4.3 Resource Estimation 60 4.4 First Prototype Construction 61 4.5 Prototype Evaluation 64 4.6 Go, No-Go Decision 65 4.7 Prototype Evolution 67 4.7.1 New Prototype Scope 67 4.7.2 Constructing New Prototypes 68 4.7.3 Testing New Prototypes 68 4.8 Prototype Release 68 4.9 Maintain Release Software 69 4.10 Summary 72 CHAPTER 5 HUMAN ASPECTS OF SOFTWARE ENGINEERING 74 5.1 Characteristics of a Software Engineer 75 5.2 The Psychology of Software Engineering 75
TABLE OF CONTENTS 5.3 The Software Team 76 5.4 Team Structures 78 5.5 The Impact of Social Media 79 5.6 Global Teams 80 5.7 Summary 81 PART TWO MODELING 83 CHAPTER 6 PRINCIPLES THAT GUIDE PRACTICE 84 6.1 Core Principles 85 6.11 Principles That Guide Process 85 6.1.2 Principles That Guide Practice 86 6.2 Principles That Guide Each Framework Activity 88 6.21 Communication Principles 88 6.2.2 Planning Principles 91 6.2.3 Modeling Principles 92 6.2. Construction Principles 95 6.2.5 Deployment Principles 98 6.3 Summary 100 CHAPTER 7 UNDERSTANDING REQUIREMENTS 102 7.1 7.1.1 10 7.1.2 Elicitation 104 713 Elaboration 104 7.14 Negotiation 105 7.1.5 cification 5 7.1.6 Validation 105 7.17 Requirements Management 106 72 Establishing the Groundwork 107 7.2.1 Identifying Stakeholders 107 7.2.2 Recognizing Multiple Viewpoints 107 7.23 Working Toward Collaboration 108 7.2.4 Asking the First Questions 108 7.2. Nontunctional Requirements 109 7.26 Traceability 109
TABLE OF CONTENTS xi 5.3 The Software Team 76 5.4 Team Structures 78 5.5 The Impact of Social Media 79 5.6 Global Teams 80 5.7 Summary 81 PART TWO MODELING 83 CHAPTER 6 PRINCIPLES THAT GUIDE PRACTICE 84 6.1 Core Principles 85 6.1.1 Principles That Guide Process 85 6.1.2 Principles That Guide Practice 86 6.2 Principles That Guide Each Framework Activity 88 6.2.1 Communication Principles 88 6.2.2 Planning Principles 91 6.2.3 Modeling Principles 92 6.2.4 Construction Principles 95 6.2.5 Deployment Principles 98 6.3 Summary 100 CHAPTER 7 UNDERSTANDING REQUIREMENTS 102 7.1 Requirements Engineering 103 7.1.1 Inception 104 7.1.2 Elicitation 104 7.1.3 Elaboration 104 7.1.4 Negotiation 105 7.1.5 Specification 105 7.1.6 Validation 105 7.1.7 Requirements Management 106 7.2 Establishing the Groundwork 107 7.2.1 Identifying Stakeholders 107 7.2.2 Recognizing Multiple Viewpoints 107 7.2.3 Working Toward Collaboration 108 7.2.4 Asking the First Questions 108 7.2.5 Nonfunctional Requirements 109 7.2.6 Traceability 109
TABLE OF CONTENTS 7.3 Requirements Gathering 110 731 Collaborative Requir 7.3.2 Usage Scenarios 7.3.3 Elicitation Work Products 114 7.4 Developing Use Cases 114 7.5 Building the Analysis Model 118 761 Elements of the Analysis model 119 7.5.2 Analysis Patterns 122 7.6 Negotiating Requirements 122 7.7 Requirements Monitoring 123 7.8 Validating Requirements 123 7.9 Summary 124 CHAPTER 8 REQUIREMENTS MODELING- A RECOMMENDED APPROACH 126 8.1 Requirements Analysis 127 8.1.1 Overall Objectives and Philosophy 128 8.1.2 Analysis Rules of Thumb 128 8.1.3 Requirements Modeling Principles 129 8.2 Scenario-Based Modeling 130 82.1 Actors and User Profiles 131 8.2.2 Creating Use Cases 131 8.2.3 Documenting Use Cases 135 8.3 Class-Based Modeling 137 8.3.1 Identifying Analysis Classes 137 8.3.2 Defining Attributes and Operations 140 83.3 UML Class Models 141 8.3.4 Class-Responsibility-Collaborator Modeling 144 8.4 Functional Modeling 146 只A1 A Procedural View 146 8.4.2 UML Sequence Diagrams 148 8.5 Behavioral Modeling 149 Q64 Identifying Events with the Use Case 149 8.5.2 UML State Diagrams 150 8.5.3 UML Activity Diagrams 151 8.6 Summary 154
xii TABLE OF CONTENTS 7.3 Requirements Gathering 110 7.3.1 Collaborative Requirements Gathering 110 7.3.2 Usage Scenarios 113 7.3.3 Elicitation Work Products 114 7.4 Developing Use Cases 114 7.5 Building the Analysis Model 118 7.5.1 Elements of the Analysis Model 119 7.5.2 Analysis Patterns 122 7.6 Negotiating Requirements 122 7.7 Requirements Monitoring 123 7.8 Validating Requirements 123 7.9 Summary 124 CHAPTER 8 REQUIREMENTS MODELING— A RECOMMENDED APPROACH 126 8.1 Requirements Analysis 127 8.1.1 Overall Objectives and Philosophy 128 8.1.2 Analysis Rules of Thumb 128 8.1.3 Requirements Modeling Principles 129 8.2 Scenario-Based Modeling 130 8.2.1 Actors and User Profiles 131 8.2.2 Creating Use Cases 131 8.2.3 Documenting Use Cases 135 8.3 Class-Based Modeling 137 8.3.1 Identifying Analysis Classes 137 8.3.2 Defining Attributes and Operations 140 8.3.3 UML Class Models 141 8.3.4 Class-Responsibility-Collaborator Modeling 144 8.4 Functional Modeling 146 8.4.1 A Procedural View 146 8.4.2 UML Sequence Diagrams 148 8.5 Behavioral Modeling 149 8.5.1 Identifying Events with the Use Case 149 8.5.2 UML State Diagrams 150 8.5.3 UML Activity Diagrams 151 8.6 Summary 154
TABLE OF CONTENTS i CHAPTER 9 DESIGN CONCEPTS 156 9.1 Design Within the Context of Software Engineering 157 9.2 The Design Process 159 9.2.1 Software Quality Guidelines and Attributes 160 9.2.2 The Evolution of Software Design 161 9.3 Design Concepts 163 9.3.1 Abstraction 163 9.3.2 Architecture 163 933 Patterns 164 9.3.4 Separation of Concerns 165 9.3.5 Modularity 165 936 Information Hiding 166 937 Functional Independence 167 9.3.8 Stepwise Refinement 16 9.3.9 Refactoring 168 9.3.10 Design Classes 169 9.4 The Design Model 171 9.4.1 Design Modeling Principles 173 9.4.2 Data Design Elements 174 9.43 Architectural Design Elements 175 9.4.4 Interface Design Elements 175 9.4. Component-Level Design Elements 176 9.46 Deployment-Level Design Elements 177 9.5 Summary 178 CHAPTER 10 ARCHITECTURAL DESIGN- A RECOMMENDED APPROACH 181 101 Software architecture 182 10.1.1 What Is Architecture?182 10.1.2 Why Is Architecture Important? 183 10.1.3 Architectural Descriptions 183 10.1.4 Architectural Decisions 184 10.2 Agility and Architecture 185 10.3 Architectural Styles 186 10.3.1 A Brief Taxonomy of Architectural Styles 187 10.3.2 Architectural Patterns 192 10.3.3 Organization and Refinement 193
TABLE OF CONTENTS xiii CHAPTER 9 DESIGN CONCEPTS 156 9.1 Design Within the Context of Software Engineering 157 9.2 The Design Process 159 9.2.1 Software Quality Guidelines and Attributes 160 9.2.2 The Evolution of Software Design 161 9.3 Design Concepts 163 9.3.1 Abstraction 163 9.3.2 Architecture 163 9.3.3 Patterns 164 9.3.4 Separation of Concerns 165 9.3.5 Modularity 165 9.3.6 Information Hiding 166 9.3.7 Functional Independence 167 9.3.8 Stepwise Refinement 167 9.3.9 Refactoring 168 9.3.10 Design Classes 169 9.4 The Design Model 171 9.4.1 Design Modeling Principles 173 9.4.2 Data Design Elements 174 9.4.3 Architectural Design Elements 175 9.4.4 Interface Design Elements 175 9.4.5 Component-Level Design Elements 176 9.4.6 Deployment-Level Design Elements 177 9.5 Summary 178 CHAPTER 10 ARCHITECTURAL DESIGN— A RECOMMENDED APPROACH 181 10.1 Software Architecture 182 10.1.1 What Is Architecture? 182 10.1.2 Why Is Architecture Important? 183 10.1.3 Architectural Descriptions 183 10.1.4 Architectural Decisions 184 10.2 Agility and Architecture 185 10.3 Architectural Styles 186 10.3.1 A Brief Taxonomy of Architectural Styles 187 10.3.2 Architectural Patterns 192 10.3.3 Organization and Refinement 193
TABLE OF CONTENTS 10.4 Architectural Considerations 193 10.5 Architectural Decisions 195 106 Architectural Desian 196 10.6.1 Representing the System in Context 196 10.6.2 Defining Archetypes 197 10.6.3 Refining the Architecture into Components 198 10.6.4 Describina Instantiations of the System 200 10.7 Assessing Alternative Architectural Designs 201 107.1 Architectural Reviews 202 10.72 Pattern-Based architecture Review 203 10.7.3 Architecture Conformance Checking 204 10.8 Summary 204 CHAPTER 11 COMPONENT-LEVEL DESIGN 206 11.1 What Is a Component?207 1111 An Object-Oriented View 207 1112 The Traditional view 209 11.1.3 A Process-Related View 211 11.2 Designing Class-Based Components 212 11.21 Basic Design Principles 212 11.2.2 Component-Level Design Guidelines 215 11.2.3 Cohesion 216 1124 Coupling 218 11.3 Conducting Component-Level Design 219 11.4 Specialized Component-Level Design 225 1141 Component-Level Design for WebApps 226 11.4. Component-Level Design for Mobile Apps 226 11.4.3 Designing Traditional Components 227 11.4.4 Component-Based Development 228 11.5 Component Refactoring 230 11.6 Summary 231 CHAPTER 12 USER EXPERIENCE DESIGN 233 12.1 User Experience Design Elements 234 12.1.1 Information Architecture 235 12.1.2 User Interaction Design 236 12.1.3 Usability Engineering 236 12.1.4 Visual Design 237
xiv TABLE OF CONTENTS 10.4 Architectural Considerations 193 10.5 Architectural Decisions 195 10.6 Architectural Design 196 10.6.1 Representing the System in Context 196 10.6.2 Defining Archetypes 197 10.6.3 Refining the Architecture into Components 198 10.6.4 Describing Instantiations of the System 200 10.7 Assessing Alternative Architectural Designs 201 10.7.1 Architectural Reviews 202 10.7.2 Pattern-Based Architecture Review 203 10.7.3 Architecture Conformance Checking 204 10.8 Summary 204 CHAPTER 11 COMPONENT-LEVEL DESIGN 206 11.1 What Is a Component? 207 11.1.1 An Object-Oriented View 207 11.1.2 The Traditional View 209 11.1.3 A Process-Related View 211 11.2 Designing Class-Based Components 212 11.2.1 Basic Design Principles 212 11.2.2 Component-Level Design Guidelines 215 11.2.3 Cohesion 216 11.2.4 Coupling 218 11.3 Conducting Component-Level Design 219 11.4 Specialized Component-Level Design 225 11.4.1 Component-Level Design for WebApps 226 11.4.2 Component-Level Design for Mobile Apps 226 11.4.3 Designing Traditional Components 227 11.4.4 Component-Based Development 228 11.5 Component Refactoring 230 11.6 Summary 231 CHAPTER 12 USER EXPERIENCE DESIGN 233 12.1 User Experience Design Elements 234 12.1.1 Information Architecture 235 12.1.2 User Interaction Design 236 12.1.3 Usability Engineering 236 12.1.4 Visual Design 237
TABLE OF CONTENTS 12.2 The Golden Rules 238 12.2.1 Place the User in Control 238 1222 Reduce the User's Memory Load 239 12.2.3 Make the Interface Consistent 240 12.3 User Interface Analysis and Design 241 1231 Interface Analysis and Design Models 241 12.3.2 The Process 242 12.4 User Experience Analysis 243 1241 User Research 244 12.4.2 User Modelir ng 245 12.4.3 Task Analysis 247 1244 Work Environment Analysis 248 12.5 User Experience Design 249 12.6 User Interface Design 250 12.6.1 Applying Interface Design Steps 251 12.6.2 User Interface Design Patterns 252 12.7 Design Evaluation 253 12.7. Prototype Review 253 12.7.2 User Testing 255 12.8 Usability and Accessibility 255 12.8. Usability Guidelines 257 12.8.2 Accessibility Guidelines 259 12.9 Conventional Software UX and Mobility 261 12.10 Summary 261 CHAPTER 13 DESIGN FOR MOBILITY 264 13.1 The Challenges 265 1311 Development Considerations 265 13.1.2 Technical Considerations 266 13.2 Mobile Development Life Cycle 268 132. User Interface Design 270 13.2.2 Lessons Learned 271 13.3 Mobile Architectures 273 13.4 Context-Aware Apps 274 13.5 Web Design Pyramid 275 13.5. WebApp Interface Design 275 13.52 Aesthetic Design 277 13.5.3 Content Design 277 13.5.4 Architecture Design 278 13.5.5 Navigation Design 280
TABLE OF CONTENTS xv 12.2 The Golden Rules 238 12.2.1 Place the User in Control 238 12.2.2 Reduce the User’s Memory Load 239 12.2.3 Make the Interface Consistent 240 12.3 User Interface Analysis and Design 241 12.3.1 Interface Analysis and Design Models 241 12.3.2 The Process 242 12.4 User Experience Analysis 243 12.4.1 User Research 244 12.4.2 User Modeling 245 12.4.3 Task Analysis 247 12.4.4 Work Environment Analysis 248 12.5 User Experience Design 249 12.6 User Interface Design 250 12.6.1 Applying Interface Design Steps 251 12.6.2 User Interface Design Patterns 252 12.7 Design Evaluation 253 12.7.1 Prototype Review 253 12.7.2 User Testing 255 12.8 Usability and Accessibility 255 12.8.1 Usability Guidelines 257 12.8.2 Accessibility Guidelines 259 12.9 Conventional Software UX and Mobility 261 12.10 Summary 261 CHAPTER 13 DESIGN FOR MOBILITY 264 13.1 The Challenges 265 13.1.1 Development Considerations 265 13.1.2 Technical Considerations 266 13.2 Mobile Development Life Cycle 268 13.2.1 User Interface Design 270 13.2.2 Lessons Learned 271 13.3 Mobile Architectures 273 13.4 Context-Aware Apps 274 13.5 Web Design Pyramid 275 13.5.1 WebApp Interface Design 275 13.5.2 Aesthetic Design 277 13.5.3 Content Design 277 13.5.4 Architecture Design 278 13.5.5 Navigation Design 280