Added the ability to dispatch a received message to its handlers.