In software engineering, structural design patterns help delineate clean relationships between objects and simplify design. Unlike creational patterns that we saw previously, these patterns are quite varied and represent a bouquet of recipes for various situations.
Structural design patterns
Adaptor
Many times when you code, you come across situations where you have a new requirement, and a component that almost meets that requirement. A non-software example of this situation is the power adapter: a three-legged plug from India can't be connected to a two-pronged outlet in the US. You need to use a power adapter to enable compatibility and use both entities.
In the pattern, there is an adaptor class that proxies what...