Dfa.Predefined (dfa v0.2.1)
Dfa.Predefined only predefines a behavior of state machine.
The state machine here consists of machineand instance.
Link to this section Summary
Functions
Deletes an instance.
Check if a given machine name exists.
Generate an instance of a state machine.
Check if given instance name exists.
Defines a state change event.
Removes a state change event.
Load a state.
Triggers an event.
Link to this section Functions
Link to this function
deinitialize!(instance_name, db_index)
Specs
deinitialize!(String.t(), integer()) :: Redix.Protocol.redis_value() | nil
Deletes an instance.
Link to this function
exists?(machine_name, db_index)
Specs
Check if a given machine name exists.
Link to this function
initialize!(instance_name, machine_name, db_index, initial_state)
Generate an instance of a state machine.
Link to this function
instance_exists?(instance_name, db_index)
Check if given instance name exists.
Link to this function
on!(machine_name, db_index, event, current_state, next_state)
Defines a state change event.
Link to this function
rm!(machine_name, db_index, event)
Removes a state change event.
Link to this function
state!(instance_name, db_index)
Load a state.
Link to this function
trigger!(instance_name, db_index, event)
Triggers an event.