vault backup: 2025-01-21 15:34:34
This commit is contained in:
7
.obsidian/workspace.json
vendored
7
.obsidian/workspace.json
vendored
@@ -413,7 +413,8 @@
|
||||
"title": "Design Patterns by Construx"
|
||||
}
|
||||
}
|
||||
]
|
||||
],
|
||||
"currentTab": 1
|
||||
},
|
||||
{
|
||||
"id": "03566a73db019f21",
|
||||
@@ -460,12 +461,12 @@
|
||||
}
|
||||
]
|
||||
},
|
||||
"active": "48fea0adee6bac61",
|
||||
"active": "0276c662bb61f53b",
|
||||
"lastOpenFiles": [
|
||||
"5 Media/0 Books/More Effective Agile by Steve McConnell.md",
|
||||
"5 Media/8 Courses/Design Patterns by Construx.md",
|
||||
"5 Media/0 Books/Software Project Survival Guide by Steve McConnell.md",
|
||||
"Temporary/Agile Implementation Plan.md",
|
||||
"5 Media/8 Courses/Design Patterns by Construx.md",
|
||||
"Temporary/Startup Culture List.md",
|
||||
"0 Journal/0 Daily/2025-01-21.md",
|
||||
"Attachments/Pasted image 20250120140041.png",
|
||||
|
||||
@@ -128,8 +128,8 @@ Principle of least knowledge.
|
||||
a.b().c() breaks the law --> violates coupling
|
||||
a.b() doesn't break the law
|
||||
|
||||
### Design for Invariants, Design for Change
|
||||
Product Families: attack different target markets with different value propositions with the same base platform: (pickup truck and suv example. For ford it's the same car (slight difference in build but 95% the same)).
|
||||
### Design to Invariants, Design for Change
|
||||
Product Families: attack different target markets with different value propositions with the same base platform: (pickup truck and SUV example. For ford it's the same car (slight difference in build but 95% the same)).
|
||||
The **core of the software design is made for the invariants**, meaning all the things that do not change and are the same throughout the software. An example might be the base driver code and the base I2C/SPI interface, which all the drivers use. Every driver has different registers that need to be set with different values, but the core structure can be designed to be invariant.
|
||||
Design for Change means the same thing: to *separate common from variable functionality*: use templates, inheritance, conditional compilation, frameworks.
|
||||
*Hide variation behind abstract interfaces*: Outside sees a routine that moves data from A to B and doesn't care how it is being done. It can be done by ftp, scp, tcp/ip, bluetooth, etc. Design patterns that make abstract interfaces are adapter, bridge, strategy, factory method, abstract factory, template method, iterator, decorator, proxy, etc. The client side code does not need to be changed when the bridge implementation changes.
|
||||
|
||||
Reference in New Issue
Block a user