You can insert a new State in the State Machine table, using one of following methods:
· | In the top left cell in the State Machine table, move the cursor to the word to display a + at the end of the word; click on the + to create a new State |
· | Right-click in the top left cell in the State Machine table to display the context menu, and select the menu option |
· | Right-click on an existing State cell in the State Machine table to display the context menu, and select the |
· | option to insert a new State before the current State, or |
· | option to insert a new State after the current State |
· | Click on an existing State cell in the State Machine table, and press to create and insert a new State above the selected State |
· | In the Enterprise Architect UML Toolbox, on the State Elements page, click on an element and then click on: |
· | the diagram background to add a new State to the end of the table, or |
· | an existing State cell to add the new State just above it. |
Note: From the State Elements page of the Enterprise Architect UML Toolbox you can insert State, Initial, Final, Entry, Exit and Terminate elements.
Add a Substate
To add a Substate to a selected State, follow the steps below:
1. | Right-click on the required State cell in the State Machine table. The context menu displays. |
2. | Select the menu option. Enterprise Architect adds the Substate to the State. |
Note: If the selected State does not allow a Substate, then the menu option is grayed out.
You can also drag one existing State over another. If the second State allows Substates, the dragged State then becomes its Substate.
Similarly, you can change the parent State of a Substate by dragging the Substate from the original parent State to a different State.
Remove Parent Relation of a Substate
To remove the parent relation of a Substate and make it a separate State, follow the steps below:
1. | Right-click on the Substate in the State Machine table. The context menu displays. |
2. | Select the menu option. The Substate cell becomes a State cell. |
You can also drag and drop the Substate onto the top left cell of the State Machine table.The dragged Substate again becomes a State cell.