States
States are where you can store information when a usecase is run so that it can be used again in another usecase execution.
Using state in usecase rules
process()
function injects state
parameter so that it can be called.
Set state
Signature
Set a project-wide state value to a key.
If the specified key already has value, the supplied value need to be of the same type. By doing so, the previous state will be overwritten.
Accessing state
Signature
Retrieve a value of state with specified key previously set.
If key does not exist, return undefined
instead.
Removing state
Signature
Remove a state with the specified key
Last updated