Design: Bridge Pattern Implementation
Design and implement the Bridge pattern for a simple example such as shapes with different drawing APIs. Out of scope: complex UI frameworks or third-party libraries.
Functional Requirements
FR1: Separate an abstraction from its implementation so both can vary independently
FR2: Support multiple implementations for the same abstraction
FR3: Allow adding new abstractions and implementations without changing existing code
FR4: Enable clients to use abstractions without knowing about implementation details
Non-Functional Requirements
NFR1: Design should minimize code duplication
NFR2: Should be easy to extend with new abstractions or implementations
NFR3: Low coupling between abstraction and implementation
NFR4: Code should be maintainable and testable