结构型模式
Software Architecture & Engineering · 7 notes
- Proxy Patternhistorical
The proxy pattern adds functionality through a proxy object without mixing unrelated logic into business code. These notes record implementations through examples.
- Decorator Patternhistorical
The decorator pattern adds functionality while retaining existing code by wrapping an object with additional behavior. These notes record the approach through examples.
- Adapter Patternhistorical
The adapter pattern translates between interfaces so an existing implementation can work through a different interface. These notes record that compatibility approach through code.
- Flyweight Patternhistorical
The flyweight pattern reuses many identical or similar objects to reduce repeated creation. These notes examine shared-object organization through examples.
- Facade Patternhistorical
The facade pattern places a complex process behind a unified entry point so callers can access internal functionality through a simpler interface.
- Bridge Patternhistorical
The bridge pattern handles class structures that vary along multiple dimensions. These notes use examples to show how to separate and combine those dimensions.
- Composite Patternhistorical
The composite pattern represents parts and wholes in a tree so callers can access leaf and container nodes consistently.