Sync Bridge to Java 25: H6 file labels, README mapping

This commit is contained in:
2026-06-24 14:27:07 +05:30
parent 8471913dbd
commit 4091345b20
8 changed files with 58 additions and 89 deletions

View File

@@ -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