What is the difference between Chain Of Responsibility design pattern and using a simple if-elseif-else block?
I was just looking up Chain Of Responsibility the other day, and I came across this example. Basically, there is an abstract handler, and then are concrete handlers, each of which implement the handle method of the parent abstract handler. The implementation is such that at first there is a check to see if this particular handler can process the current request, and if not, then it passes on the request to its successor. Now, I could also do the same thing using a simple if-else conditional block. To take the first example from the link above, here is how I would change it: class SingleHandler