Font size

Initial state pointer

Initial state pointer points to the initial state within a composite state. If the control is passed to a composite state, a simple state is found inside it by following the initial state pointers down the state hierarchy, and this state becomes current.

There should be exactly one initial state on each level in each composite state.

To draw an initial state pointer

  1. Drag the Initial State Pointer element from the Statechart palette onto the diagram of agent (right to the place where you want to locate it).
  2. Drag the ending point of the initial state pointer onto the border of a state or pseudo state.



Name – The name of the initial state pointer. The name is used to identify and access the initial state pointer from code.

Ignore – If selected, the initial state pointer is excluded from the model.

Show name – If selected, the name of the initial state pointer is displayed on a presentation diagram.

Action – Here you can write Java code to be executed when the initial state pointer forwards the control to an initial state.

The initial state of the whole statechart is defined not with an initial state pointer, but with a statechart entry point.

How can we improve this article?