Added hooks for before and after parsing.  Also added support for hooks to cancel all processing early.