Adapter Pattern
Status: draft · Confidence: medium (0.87) · Basis: verified_sources
Quality notes: generic_source_homepage, no_verified_sources, partial_source_verification, high_confidence_evidence_gap
## TL;DR Converts interface of a class into another interface clients expect. Lets incompatible interfaces work together. Object adapter (composition) preferred over class adapter (inheritance). ## Core Explanation Example: wrapping a third-party logging library behind your application's Logger interface, enabling easy replacement. Adapter vs. Facade: Adapter changes interface; Facade simplifies a complex subsystem with a new unified interface. Bridge pattern separates abstraction from implementation. ## Further Reading - [Design Patterns (Gang of Four)](undefined) ## Related Articles - [Command Pattern](../command-pattern.md) - [Decorator Pattern](../decorator-pattern.md) - [Factory Method Pattern](../factory-method-pattern.md)