Tool Mentor: Using Rational Rose® to Document the
Process View
Purpose
To represent the Process View and related artifacts in Rational Rose®98.
Related Rational Unified Process Activities: Describe Concurrency
Overview
The following steps are performed to manage the Process View:
- Creating
the Process View in the Logical View
- Representing
Processes using 'Active Classes' in the Process Model
- Representing Process
and Thread Life-cycles
- Allocating Classes to
Processes and Threads
The Process View can be represented in using a package within the Logical View named
"Process View". To create such a package:
- Right-click to select the Logical View in the browser.
- Select Package from the New option on the short-cut menu. A
"NewPackage" browser icon is added to the browser.
- With the new package icon selected, type the name "Process View".
Processes and threads are represented using Active Classes in UML. To
create active classes in the Process View:
- Right-click to select the "Process View" package in the browser and make the
short-cut menu visible.
- Select Class from the New option on the short-cut menu. A
"NewClass" class icon is added to the browser.
- While the new class is still selected, type the name of the class.
- Double-click on the class to display the class specification.
- In the 'Stereotype' field, enter 'process' if the active class represents a process, or
'thread'' if it represents a thread.
Process and thread life-cycles are represented in Rational Rose® using Sequence
Diagrams.
Each process or thread should appear in the sequence diagrams which create it and which
destroy it. In addition, it is useful to illustrate complex inter-process and
inter-thread communication using additional sequence diagrams. These sequence
diagrams should be organized with the Use Case Realization in which the behavior occurs.
To create a sequence diagram:
- Right-click to select the Use-Case Realization in the browser and make the short-cut
menu visible.
- Select Sequence Diagram from the New option on the short-cut menu. A
"NewDiagram" sequence diagram icon is added to the browser.
- With the new sequence diagram selected, type the name of the sequence diagram. Give it a
short, descriptive name which conveys the name of the scenario which is being documented.
To create objects in sequence diagrams:
- Double-click on the sequence diagram in the browser to open it up in the diagram window.
- Click to select the object icon from the toolbar. The cursor changes to a cross-hair
when positioned over the diagram window.
- Click over the desired position in the sequence diagram window to place the object.
- Open the Object Specification dialog box for the object, either by
double-clicking on the object symbol, or by right-clicking and selecting the Specification
option in the short-cut menu.
- In the Name field, enter the name of the object (optional). For labeling
conventions, show the initiator of the first message as the interface itself.
- In the Class field, if not already defined, select its class from the
scroll list. The scroll list contains all classes that are defined in the Rational
Rose model.
To create a message in a sequence diagram:
- Click to select the object message symbol from the toolbar.
- Click on object sending the message and drag the message line to the object receiving
the message.
- Enter the name of the message while the message line is still selected.
- Repeat the preceding steps for each message needed to support the operation behavior.
To rearrange the time-order of messages in a sequence diagram:
- Select the message arrow and drag-and-drop messages up and down the time axis to
rearrange the order.
Classes and subsystems may be allocated to one or more processes and threads.
Processes and threads are composed-of instances of classes and subsystems. To show
this allocation, class diagrams are drawn to model the processes and threads as active
classes, and to show the composition of the active classes.
To create a class diagram and insert a class in the diagram, do the following:
- Right-click to select the package/subsystem in the browser and make the short-cut menu
visible.
- Select Class Diagram from the New option on the short-cut menu. A
"NewDiagram" class diagram is added to the browser.
- While the class diagram is still selected, type the name of the class diagram; name the
diagram after the class(es) that it is meant to describe.
- Click to select the class in the browser.
- Drag-and-drop the class(es) onto the class diagram; relationships between classes in the
diagram are automatically displayed.
To create an aggregation association between the active class and a class which it
contains:
- Select the aggregation tool icon from the tool palette by right-clicking it. The
mouse pointer will change to an "up-arrow"
- Point to the class which is to be contained in the active class and press the left mouse
button down; do not release it yet.
- Holding the left mouse button down, drag the mouse pointer to the active class which
will contain the selected class; release the left mouse button.
- Double-click on the just-created aggregation association.
- Click on the 'Role A Detail' tab.
- Click on the containment 'By Value' radio button.
- Click 'OK' on the property sheet.
|