3.2.10 Connectables and
ports.
Relationship symbols can have only one connectable. If you try
to create more than one, you will be prevented and a warning dialog will be
shown. Object symbols can have many Connectables, but each of them must have a
unique identifier, provided by ports Connectables thus serve as visualization
for ports in object symbols.
A typical requirement for an object type with several
ports is that its symbol should define a separate connection for each port.
Rather than enclosing the whole symbol, these Connectables normally enclose a
small part of the symbol: e.g. one edge, or a visible ‘plug’ on the
edge of the symbol.
To attach a port to a connectable:
| 1) | Open
the Format Dialog for the connectable and go to the Connectable tab (see
Figure
3–14). |
| 2) | In
the Port(s) list, press the right mouse button to open the pop-up
menu. |
| 3) | Choose
Add... if you want to create and add a new port. This will open the
property dialog in which you can enter the values for the new port (see Section
2.5.5 for more information on how port
property values can be used as
constraints). |
| | If
you want to add an existing port, choose Add Existing.... A list of
existing port instances will be shown and you can pick the one you
want. |
To remove a port from a connectable, select
the port in the Port(s) list in the Connectable tab of the
Connectable’s Format Dialog, and select Remove from the pop-up
menu. To access and edit port properties, select Properties... from the
pop-up menu.
It is possible to attach several ports to one connectable.
However, each port may be attached to only one connectable within the same
symbol. This is, as stated before, due to the fact that ports are used as
connectable identifiers when one symbol contains several Connectables. It is
also important to understand that the omission of ports is considered as an
identifier also, which means that there can be only one connectable without
ports in an object symbol. If you try to save a symbol that breaks these rules,
an error message is shown and the symbol is not
saved.