An inherent concern of OO design: how can we extent a class without modifying its content? If we can do that, we satisfy the Open/Closed Principle (the O in SOLID).
Let’s take an example, a class
Rectangle with a method
Continue reading “Decorator pattern: decorators still need to be reused”