A lifeline represents an individual participant in the Interaction. The lifeline represents only one interacting entity, symbolized by a rectangle. The following steps show you how to work with a lifeline: To assign a type (classifier) to a lifeline, do one of the following: On the diagram, select a lifeline, and in the name area, type the “:” and the name of the type. Press Enter or click anywhere on the diagram. The type is created and assigned. Type the “:”, press Ctrl+Space, or Ctrl+Backspace. In the open list, select the type. To hide/show a base classifier You can display lifelines on the Sequence or Communication diagram in the following ways: There are two situations in which you can use the Display Lifelines dialog to automatically display lifelines: To display lifelines when creating a new diagram To display lifelines in a preexisting diagram The “dot notation” is available for the lifelines. Now you can send messages directly to the deeply nested parts. To display a deeply nested part Create a Sequence diagram. The Display Lifelines dialog opens. You can open the Display Lifelines dialog in the existing diagram. On the diagram pane, click the right mouse button and from the shortcut menu, select Related Elements > Display Lifelines. Select a nested part you want to display. Make sure that the nesting part is not selected, otherwise it will be displayed instead of the nested part. By default, when there is a message sent between lifelines in a sequence diagram, the lifelines are displayed with activation bars on them. However, you can hide the activation bars from the diagram.Assigning a type to a lifeline
Showing/hiding a base classifier
Displaying lifelines
Selected lifelines are displayed on the diagram pane.
Selected lifelines are displayed on the diagram pane.Deeply nested parts
Activation bars on lifelines
To hide activation bars from lifelines in a sequence diagram
Sample model
The models used in the figures of this page is the Communication diagram and Sequence diagram sample models.
To open this sample
- Find in modeling tool:
- <modeling tool installation directory>\samples\diagrams\communication diagram.mdzip.
- <modeling tool installation directory>\samples\diagrams\sequence diagram.mdzip.