v0.7.0
Added
- Add support for async guards and actions
- Add name to statemachine and make dot output stable and unique (issue-62)
- Add derive macros to states and events (issue-62)
- Add hooks to
StateMachineContext
for logging events, guards, actions, and state changes - Add support multiple guarded transitions for a triggering event
- Add support for guard boolean expressions in the state machine declaration
- There are now
on_entry_<snakecase_statename>
andon_entry_<snakecase_statename>
functions
defined to allow handling entry and exit from all state machine states. These have a default empty
implementation.
Fixed
Changed
StateMachine::new
andStateMachine::new_with_state
are now const functions- Fixed clippy warnings
- [breaking] Changed guard functions return type from Result<(),> to Result<bool,>
- [breaking] Changed action functions return type from () to Result<NextStateData,_>
- [breaking] Disallow guards mutable access to the context
- [breaking] Renamed GuardError to Error as it is now used for both guards and actions
New Contributors
- @maximeborges made their first contribution in #64
- @asmfreak made their first contribution in #62
- @mhammerly made their first contribution in #68
- @dkumsh made their first contribution in #72
- @MartinBroers made their first contribution in #66
Full Changelog: v0.6.0...v0.7.0