Add treat all transitions as hard

Adds the new StateMachine.treat_all_transitions_as_hard! config option, as well as a new InvalidEvent error class.