state_machine v0.1.1 StateMachine.State behaviour
Link to this section Summary
Link to this section Types
Link to this type
t(model)
t(model)
t(model) :: %StateMachine.State{
after_enter: [StateMachine.Callback.t(model)],
after_leave: [StateMachine.Callback.t(model)],
before_enter: [StateMachine.Callback.t(model)],
before_leave: [StateMachine.Callback.t(model)],
name: atom()
}
t(model) :: %StateMachine.State{ after_enter: [StateMachine.Callback.t(model)], after_leave: [StateMachine.Callback.t(model)], before_enter: [StateMachine.Callback.t(model)], before_leave: [StateMachine.Callback.t(model)], name: atom() }
Link to this section Functions
Link to this function
after_enter(ctx)
after_enter(ctx)
after_enter(StateMachine.Context.t(model)) :: StateMachine.Context.t(model)
after_enter(StateMachine.Context.t(model)) :: StateMachine.Context.t(model)
Link to this function
after_leave(ctx)
after_leave(ctx)
after_leave(StateMachine.Context.t(model)) :: StateMachine.Context.t(model)
after_leave(StateMachine.Context.t(model)) :: StateMachine.Context.t(model)
Link to this function
before_enter(ctx)
before_enter(ctx)
before_enter(StateMachine.Context.t(model)) :: StateMachine.Context.t(model)
before_enter(StateMachine.Context.t(model)) :: StateMachine.Context.t(model)
Link to this function
before_leave(ctx)
before_leave(ctx)
before_leave(StateMachine.Context.t(model)) :: StateMachine.Context.t(model)
before_leave(StateMachine.Context.t(model)) :: StateMachine.Context.t(model)
Link to this function
get(ctx)
Link to this function
set(ctx, state)
Link to this section Callbacks
Link to this callback
get(ctx)
get(ctx)
get(ctx :: StateMachine.Context.t(any())) :: atom()
get(ctx :: StateMachine.Context.t(any())) :: atom()
Link to this callback
set(ctx, state)
set(ctx, state)
set(ctx :: StateMachine.Context.t(model), state :: atom()) ::
StateMachine.Context.t(model)
set(ctx :: StateMachine.Context.t(model), state :: atom()) :: StateMachine.Context.t(model)