The Decorator pattern: an easy way to add functionality

Introduction The Decorator pattern can be used to dynamically alter or add functionality to existing classes. This pattern is oftern more efficient than subclassing because it relieves us of the need of defining a new object. So, what does it…














