Advanced States and Transitions
- Entry and Exit Actions
- Internal Transitions
- Do-Activities
- Deferred Event
- Entry actions are actions done upon entry of a state and are shown by the keyword event 'entry' with an appropriate action
- Exit actions are actions done upon exit from a state marked by the keyword event 'exit', together with an appropriate action
Internal Transitions:
- Internal transitions are events handled internally without leaving the state
- Internal transitions may have events with parameters and guard conditions
- Activities that make use of object's idle time when inside a state
- 'do' transition specifies the work done inside a state after the entry action is dispatched
- A deferred event is a list of events whose occurrence in the state is postponed until a state in which the listed events are not deferred
- It becomes active at the time they occur and may trigger transitions as if they had just occurred
- A deferred event is specified by listing the event with the special action 'defer'
- Sequential Substates
- History States
- Concurrent Substates
- Sequential substates are those substates in which an event common to the composite states can easily be exercised by each state inside it at any time
- Sequential substates partition the state space of the composite state into disjoint states
- A nested sequential state machine may have at most one initial state and one final state
History States
- It allows composite state that contains sequential substates to remember the last substate that was active in it prior to the transition from the composite state
- A shallow history state is represented as a small circle containing the symbol 'H'
- The first time entry to a composite state doesn't have any history
- The symbol 'H' designates a shallow history, which remembers only the history of the immediate nested state machine
- The symbol 'H*' designates deep history, which remembers down to the innermost nested state at any depth
- If there is only one level of nesting, shallow and deep history states are semantically equivalent
Concurrent Substates
- Concurrent substates specify two or more state machines that execute in parallel, in the context of the enclosing object
- Execution of these concurrent substates continues in parallel
- These substates wait for each other to finish to join back into one flow
- A nested concurrent state machine does not have an initial, final, or history state
Social Plugin