Adapter
First of the four wrappers. All four wrap another object and forward calls; only their intent differs. Adapter is the one that changes the interface so two incompatible things can meet. Learn the four together or you will confuse them forever.
Structure
classDiagram
class Client
class Target {
<<interface>>
+request()
}
class Adapter {
+request()
}
class Adaptee {
+specificRequest()
}
Client --> Target
Target <|.. Adapter
Adapter o--> Adaptee : wraps
Telling It Apart
Patterns whose structure looks the same but whose intent does not. See the Confusing Pairs reference.