Sync Bridge to Java 25: H6 file labels, README mapping
This commit is contained in:
18
README.md
18
README.md
@@ -197,6 +197,24 @@ javac 02-structural/adapter/*.java -d out/adapter
|
||||
java -cp out/adapter adapter.Main
|
||||
```
|
||||
|
||||
### Bridge (`02-structural/bridge/`)
|
||||
|
||||
| Post Section | File(s) |
|
||||
|---|---|
|
||||
| Step 1 — The Implementor Interface | `Device.java` |
|
||||
| Step 2 — Concrete Implementors (TV and Radio) | `TV.java`, `Radio.java` |
|
||||
| Step 3 — The Abstraction (RemoteControl) | `RemoteControl.java` |
|
||||
| Step 4 — Refined Abstraction (AdvancedRemote) | `AdvancedRemote.java` |
|
||||
| Wiring It Together: Main Demo | `Main.java` |
|
||||
|
||||
Note: the "Class Explosion Problem — Visualised" pseudocode and the JDBC/SLF4J snippets are illustrative only — they are not part of this repository's runnable example.
|
||||
|
||||
Run it:
|
||||
```bash
|
||||
javac 02-structural/bridge/*.java -d out/bridge
|
||||
java -cp out/bridge bridge.Main
|
||||
```
|
||||
|
||||
## Reference
|
||||
|
||||
- *Design Patterns: Elements of Reusable Object-Oriented Software* — Gamma, Helm, Johnson, Vlissides
|
||||
|
||||
Reference in New Issue
Block a user