![]() |
![]() |
![]() |
![]() |
Creating and Displaying an Interaction Diagram Creating and Displaying an Interaction Diagram
To create or display a collaboration or sequence diagram:
- 1 Click Browse > Interaction Diagram.
- 2 Select a package to "own" the diagram.
- 3 On the right side of the dialog box, click the diagram name, and then click OK.
- 4 From the New Interaction Diagram dialog box, enter the diagram title and click the diagram type. Your choices are Sequence or Collaboration. Each diagram type is described in detail later in this chapter.
Collaboration DiagramsA collaboration diagram is an interaction diagram which shows the sequence of messages that implement an operation or a transaction. These diagrams show objects, their links, and their messages. They can also contain simple class instances and class utility instances. Each collaboration diagram provides a view of the interactions or structural relationships that occur between objects and object-like entities in the current model.
You can create one or more collaboration diagrams to depict interactions for each logical package in your model. Such collaboration diagrams are themselves contained by the logical package enclosing the objects they depict.
During analysis, collaboration diagrams can indicate the semantics of the primary and secondary interactions.
During design, collaboration diagrams can show the semantics of mechanisms in the logical design of the system.
Use collaboration diagrams as the primary vehicle to describe interactions that express your decisions about the behavior of the system. They can also be used to trace the execution of a scenario by capturing the sequential and parallel interaction of a cooperating set of objects.
Collaboration diagrams may also depict interactions that illustrate system behavior.
Figure 69 Collaboration Diagram Example
Sequence DiagramsA sequence diagram is a graphical view of a scenario that shows object interaction in a time-based sequence--what happens first, what happens next. Sequence diagrams establish the roles of objects and help provide essential information to determine class responsibilities and interfaces. Sequence diagrams are normally associated with use cases.
This type of diagram is best used during early analysis phases in design because they are simple and easy to comprehend. A sequence diagram has two dimensions: typically, vertical placement represents time and horizontal placement represents different objects.
Sequence diagrams are closely related to collaboration diagrams and each are alternate representations of an interaction.
A sequence diagram traces the execution of a scenario in time. Figure 70 shows a sequence diagram.
Figure 70 Sequence Diagram Example
ToolboxesEach diagram type has its own unique toolbox. The collaboration and sequence diagram toolboxes are illustrated in this section.
Rational Software Corporation
http://www.rational.com support@rational.com docs@us.ibm.com Copyright © 1993-2000, Rational Software Corporation. All rights reserved. |
![]() |
![]() |
![]() |
![]() |