Working with a Collaboration Use

From RAD Studio
Jump to: navigation, search

Go Up to UML 2.0 Composite Structure Diagram Procedures

This article explains how to work with a collaboration use

To create a collaboration use:

  1. On the diagram Tool Palette, choose the Collaboration Use button.
  2. Click the target container.
  3. Specify the name of the Collaboration Use.

To link to a collaboration type:

  1. Select a Collaboration Use element.
  2. Specify the type of Collaboration Use using one of the following methods:
    • In the type field of the Collaboration Use in the Object Inspector, click the chooser button, and select the collaboration, which the Collaboration Use instantiates, from the Model or Favorites.
    • Next to the name of the Collaboration Use, insert a colon and the name of the collaboration, which the Collaboration Use instantiates.

Result: The type of collaboration use is indicated next to its name.

To unlink from a collaboration type:

  1. Right-click the Collaboration Use that has a certain type assigned.
  2. On the context menu, choose Unlink Collaboration.

To bind with a role (part):

  1. On the diagram Tool Palette, choose the Role Binding button.
  2. If you hover the mouse over the client collaboration use, the valid client is highlighted with a black ellipse.
  3. Drag-and-drop the role binding link to the supplier part. The valid target is highlighted.
  4. Type the role name and press Enter to close the in-place editor.

If a collaboration use is associated with a collaboration that contains parts (roles), you can bind them with the parts (roles) of another classifier.

To bind the roles (parts) of the different classifiers via the collaboration use:

  1. Create a collaboration use and define its type.
  2. Create one or more parts in the collaboration that represents the type.
  3. Right-click the target collaboration use and choose Bind new role on its context menu.
  4. In the Select Destination dialog box that opens, choose the role to be bound in the target classifier.

Result: A role link is created from the collaboration use to the role in the target classifier. The role link is now marked with the name of the role selected in the collaboration.

Note: Each role can be used for binding only once. With the next invocation of the Bind new role command, the list of available roles no longer displays the ones previously used.

To define an owner:

  1. Right-click a collaboration use and choose Object Inspector on its context menu.
  2. In the owning classifier field of the Object Inspector, click the chooser button.
  3. In the Select Owning Classifier dialog box, navigate to the owner class or collaboration and click OK.

Result: A link is created between the owner as supplier, and the collaboration use as the client. The link is marked with the label <<represents>>.

See Also