cizen v0.3.0 Cizen.Saga behaviour View Source
The saga behaviour
Link to this section Summary
Functions
Returns a specification to start this module under a supervisor
Callbacks
Invoked when the saga receives an event
Invoked when the saga is started. Saga.Launched event will be dispatched after this callback
Link to this section Types
Link to this section Functions
Returns a specification to start this module under a supervisor.
See Supervisor
.
Link to this section Callbacks
Link to this callback
handle_event(arg0, arg1, state)
View Source
handle_event(Cizen.SagaID.t(), Cizen.Event.t(), state()) :: state()
Invoked when the saga receives an event.
Returned value will be used as the next state to pass handle_event/3
callback.
Link to this callback
init(arg0, arg1)
View Source
init(Cizen.SagaID.t(), Cizen.Saga.t()) :: state()
Invoked when the saga is started. Saga.Launched event will be dispatched after this callback.
Returned value will be used as the next state to pass handle_event/3
callback.