[1] It is often used to make existing classes work with others without modifying their source code.
An adapter can be used when the wrapper must respect a particular interface and must support polymorphic behavior.
A compile time solution is: However, suppose that the format of the string data must be varied.
A compile time solution is to use inheritance: and perhaps create the correctly "formatting" object at runtime by means of the factory pattern.
This parameter will be passed to an instance member of [ClassName]To[Interface]Adapter.