Adds State.prototype.enter, .exit, and .action methods to register
enter/exit/action handlers.