Adapter-kuvio mahdollistaa objektien, joilla on yhteensopimattomat rajapinnat, toimia yhdessä käärimällä yhden objektin rajapinnalla, jonka toinen odottaa. Se toimii kääntäjänä kahden rajapinnan välillä, mahdollistaen integraation ilman olemassa olevan koodin muuttamista.
Mitä Adapter-kuvio tekee
ADAPTER → convert one interface into another that a client expects (a "translator"):
→ wrap an object whose interface is INCOMPATIBLE, exposing the interface the client needs
→ the adapter translates calls/data between the two interfaces
→ makes incompatible things work together WITHOUT changing either's code
