December 2021
Intermediate to advanced
352 pages
10h
English
The Chain of Responsibility pattern allows a number of classes to attempt to handle a request without any of them knowing about the capabilities of the other classes. It provides a loose coupling between these classes; the only common link is the request that is passed between them. The request is passed along until one of the classes can handle it.
One example of such a chain pattern is a Help system, where every screen region of an application invites you to seek help (see Figure 20-1). There are also window background areas where more generic help is the only suitable result.
Read now
Unlock full access