Golang Decorator Pattern
Golang Decorator Pattern Decorator pattern is the one of twenty-three well-known design patter from Gang of Four design patterns. It is categorized in structural design pattern, along with Adapter pattern, Proxy pattern etc. The decorator pattern allows behavior to be added to an individual object, dynamically, without affecting the behavior of other objects from the same class.
It tries to resolve the problem that single responsibility, following the Single Responsibility Principle, should be added to or removed from an object dynamically at run-time.
Posted by Henry Du on Wednesday, January 5, 2022