Section 1 Agile Development 1
Chapter 1 Agile Practices 3
Chapter 2 Overview of Extreme Programming 11
Chapter 3 Planning 19
Chapter 4 Testing 23
Chapter 5 Refactoring 31
Chapter 6 A Programming Episode 43
Section 2 Agile Design 85
Chapter 7 What Is Agile Design? 87
Chapter 8 SRP:The Single-Responsibility Principle 95
Chapter 9 OCP:The Open-Closed Principle 99
Chapter 10 LSP:The Liskov Substitution Principle 111
Chapter 11 DIP:The Dependency-Inversion Principle 127
Chapter 12 ISP:The Interface-Segregation Principle 135
Section 3 The Payroll Case Study 147
Chapter 13 COMMAND and ACTIVE OBJECT 151
Chapter 14 TEMPLATE METHOD&STRATEGY:Inheritance vs. Delegation 161
Chapter 15 FACADE and MEDIATOR 173
Chapter 16 SINGLETON and MONOSTATE 177
Chapter 17 NULL OBJECT 189
Chapter 18 The Payroll Case Study:Iteration One Begins 193
Chapter 19 The Payroll Case Study: Implementation 205
Section 4 Packaging the Payroll System 251
Chapter 20 Principles of Package Design 253
Chapter 21 FACTORY 269
Chapter 22 The Payroll Case Study(Part2) 275
Section 5 The Weather Station Case Study 291
Chapter 23 COMPOSITE 293
Chapter 24 OBSERVER-Backing into a Pattern 297
Chapter 25 ABSTRACT SERVER,ADAPTER,and BRIDGE 317
Chapter 26 PROXY and STAIRWAY TO HEAVEN:Managing Third Party APIs 327
Chapter 27 Case Study:Weather Station 355
Section 6 The ETS Case Study 385
Chapter 28 VISITOR 387
Chapter 29 STATE 419
Chapter 30 The ETS Framework 443
Appendix A UML NotationⅠ:The CGI Example 467
Appendix B UML NotationⅡ:The STATMUX 489
Appendix C A Satire of Two Companies 507
Appendix D The Source Code Is the Design 517
Index 525