0

GOF has the following point for application of Adapter pattern:

you need to use several existing subclasses, but it's impractical to adapt their interface by subclassing every one. An object adapter can adapt the interface of its parent class

What does it mean? Please give an example of the scenario? (Code is not required)

Thanks

lynxx
  • 544
  • 3
  • 18
  • 3
    Possible duplicate of [adapter-Any real example of Adapter Pattern](https://stackoverflow.com/questions/11079605/adapter-any-real-example-of-adapter-pattern) – Sharon Ben Asher Nov 25 '19 at 09:42
  • @SharonBenAsher I just want a specific example of the listed point – lynxx Nov 25 '19 at 09:45
  • 1
    With respect to the specific suggestion of an *object adapter* (there's a *class adapter*, too), read [this question and its answers](https://stackoverflow.com/questions/9978477/difference-between-object-adapter-pattern-and-class-adapter-pattern/32795463). – deHaar Nov 25 '19 at 09:46
  • 1
    a specific example of adapting multiple subclasses can be found in the linked question – Sharon Ben Asher Nov 25 '19 at 09:46

0 Answers0