Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

Variations to this pattern:

  • we could have an explicit interface, e.g. Lister, to statically type the implementations but because of duck-typing this is optional
  • we could use a chain tree instead of a list
  • we could always pass down the chain even if we processed a request
  • we could decide at some point to not respond and not pass down the chain
  • we could use Groovy's meta-programming capabilities to pass unknown methods down the chain