addTransition

fun addTransition(startState: State, event: Event?, guardKey: GuardKey?, actionKey: ActionKey?, endState: State)

Add a transition arc.

Parameters

startState

The starting state for the arc.

event

The event that triggers the transition, possibly null if the transition should be attempted automatically upon entry of the state.

guardKey

The guard that must be satisfied for a transition to be taken, possibly null if no guard should be checked.

actionKey

The action to run during the transition, possibly null if no action should be performed during transition.

endState

The ending state.