CSE687 - Object Oriented Design

Design Note #3
Favor Local Consequences

Revised: 4/28/2011
Home Courses Code Handouts CoreTech Books Articles Math Research Masters Projects SWDev WebDev News OtherLinks SiteDesign Graduates AllPages Office Hours Notices

CSE681-SWMAA CSE686-IP CSE687-OOD CSE775-DO CSE776-DP CSE778-AWP CSE784-SWS

Cncp #01 Cncp #02 Cncp #03 Cncp #04 Cncp #05 Cncp #06 Cncp #07 Cncp #08 Cncp #09 Cncp #10 Cncp #11
Note #01 Note #02 Note #03 Note #04 Note #05 Note #06 Note #07 Note #08
Lang #01 Lang #02 Lang #03 Lang #04

Syllabus SG - Design SG - Templates SG - Class Relationships

Design Note #3:

Design your code so changes have local consequences.

Conclusions for: Favor Local Consequences

Code with only local consequences of change is easier to develop and maintain.
  1. Keep consequences local by strong encapsulation and avoiding sharing and remote delegation.
  2. Try to make most of your code satisfy this rule, but break it intentionally to do powerful things in small parts of your design.