Transition
A Transition is a type of node within a scenario.
Transitions can usually have :
- one or more upstream places.
- one (for state machines) or more downstream places.
Transitions can usually have :
- Zero or mutiple Sensor functions
- Zero or mutiple Effector functions
- A Token merge function
- A Token assign function
- A priority
Transitions can fire if :
- All upstream places contain a token
- There is no Sensor function or all the Sensor functions are valid
When a transition fires it sequentially:
- Consumes and merges (see Token Merge) all upstream places tokens
- Merges all sensors event contexts in an array of contexts. Each sensor context data path is prefixed with it's order number (i.e. the first sensors context data is in
EventContext.0.xxxxx
) - Sequencially runs all the Effector functions (see Effector)
- Assigns a token in every downstream place (see Token Assign) (note that if at least one of these downstream place contains a token, an error occurs)
Transitions also contain a priority value, defaulted to zero. A higher priority transition gets to be checked before lower priority transitions. For more details on the order in which all functions of a transition are called, see Safe Petri Network.