Tweaked formatter code to throw narrower exception and message callback code to throw exception from handle method.
Refactored formatters out to a toplevel package.