Chain of Responsibility: Implementation
There are 2 basic ways to pass commands through a chain of responsibility.
- Encapsulate each kind of command in a single object that can be passed to a single postCommand method.
- Have as many different types of postCommand and handleCommand methods as there are different types of information associated with commands.