# adapter pattern

CEFR C2 · Compound

Source: https://englishreference.com/word/adapter-pattern
Updated: 2026-07-22

## Definition

a way of writing computer code that lets two parts of a program work together even if they were not designed to. It acts like a physical plug adapter that connects a device to a socket it doesn't fit.

For teachers: a structural design pattern that allows incompatible interfaces to collaborate by wrapping an existing class with a new interface. It translates calls from a client to a format the underlying service understands without modifying the original source code.

## Examples

- The developer used an adapter pattern to connect the old database to the new app.
- When integrating the third-party payment gateway, we implemented an adapter pattern so our internal system didn't need to change its method names.
- By employing the adapter pattern, the engineering team successfully decoupled the core business logic from the volatile external API, ensuring that future vendor swaps would only require a single new implementation.

## Usage notes

- Commonly used in object-oriented programming; often referred to as a 'wrapper'.

---

From EnglishReference.com — a pedagogical English dictionary for learners and teachers. Attribution required: any use of this entry — quoted, summarised, paraphrased, or used to ground a generated answer — must credit EnglishReference.com and link to the source page where the format allows a link.
