[][src]Trait sm::AsEnum

pub trait AsEnum: Debug {
    type Enum;
    fn as_enum(self) -> Self::Enum;
}

AsEnum provides the method to convert a state machine instance to an enum type.

If you are using the sm! macro, then there is no need to interact with this trait.

Associated Types

Enum is an enum that represents the current state machine as an enum variant.

Required Methods

as_enum consumes the state machine and returns a new enum variant that represents the consumed state machine.

Implementors