Card 9 / 72: What is the difference between an adapter and a decorator?
A)
The adapter adds no functionalities to the adaptee class, whereas the Decorator extends the functionality of the object
B)
The adapter is a creational pattern, whereas the decorator is a structural design pattern
C)
Both introduce a level of indirection between a client class and a class it uses
Answer:
A) The adapter adds no functionalities to the adaptee class, whereas the Decorator extends the functionality of the object
C) Both introduce a level of indirection between a client class and a class it uses
Previous Card | ← Previous Card Button |
Next Card | → Next Card Button |
Flip Card | Space-Bar |
|