rs_state_machine 2.0.0

A business-oriented state machine library
Documentation
1
2
3
4
5
6
7
8
9
/// Implement the [Transitionable] trait to use the [Machine](super::machine::Machine) directly with your structures.
pub trait Transitionable<S> {

    /// Returns the current state of a structure.
    fn get_state(&self) -> S;
    
    /// Sets a new state in the structure.
    fn set_state(&mut self, new_state: S);
}