Allow a new Dispatcher class to be set.

This allows a new Dispatcher to be set.

For example see the Tests included in this Pull Request.