Showing all relations for a class, object, or package in a
diagram
To show a class and its relations to all the other elements
in a project, create an object model diagram in IBM® Rational® Rhapsody®.
About this task
You can show the
relations for a class, an object, and a package. You would use the
same procedure as noted, except that you would select that particular
element (for example, an object) instead.
To
show all the relations of a class:
Procedure
Right‑click a class in the product browser
and select Show Relations in New Diagram.
Notice the following information:
Rational Rhapsody created
an object model diagram that shows all the relations for the selected
class.
Rational Rhapsody also
named the new object model diagram from the name of the class you
selected and it created an Object Model Diagram category to
hold the new diagram within the package where the class resides.
Results
Note the following information:
The Show Relations in New Diagram menu
command is available for classes, objects, and packages from the product
browser as well as on a diagram. For both the browser and on a diagram,
you would right-click the element (for example, an object) and select Show
Relations in New Diagram.
Note: For a diagram
you can select multiple elements (for example, two classes). Use Ctrl+Click to
make multiple selections and then right‑click one of the selected
elements to open the menu and click Show Relations in New
Diagram.
The location of the new object model diagram created
by Show Relations in New Diagram depends on whether you started
the command from the browser or a diagram:
When started from the browser, Show
Relations in New Diagram creates the diagram in the same
location as the selected element and places it in an Object Model
Diagram category (which the product creates if the category is
not already available).
When started from a diagram, Show Relations
in New Diagram creates the object model diagram in the
same location in which the source diagram resides.
The new object model diagram created by Show
Relations in New Diagram is named the same name as the
class, object, or package from which it was created. If there is already
an object model diagram with that name, a number is appended to the
name (for example, Dishwasher_9).