Parts

In composite structure diagrams, a part is a diagram element that represents a set of one or more instances that a containing structured classifier owns. A part describes the role of an instance in a classifier. You can create parts in the structure compartment of a classifier, and in several UML diagrams such as composite structure, class, object, component, deployment, and package diagrams.

Parts are owned by composition and the composite structure diagram models how the parts are connected in the containing classifier. Each part is a specific usage of a type. The type defines the kinds of objects that can be bound, or referenced, to a role. You can have multiple parts with the same type and each part can have a different set of relationships to other parts. You can join parts with connectors to specify the communication between them.

As the following figure illustrates, a part is displayed in the diagram frame as a solid rectangle that contains the name of the part, the type, and any specified multiplicity.

A diagram frame shows four rectangles,
each representing one part of the type Wheel that belongs to the containing
classifier. A connector, displayed as a straight line connecting the rectangles,
links the two front wheels and the two rear wheels.

The example in the figure shows a containing classifier named Car. The composite structure diagram shows the four composite parts of the car, which each represent a wheel type. The frontaxle connector links the front wheels and the rearaxle connector links the rear wheels.

Related tasks
Adding parts to composite structure diagrams
Changing the type of classifiers for parts
Connecting parts and ports in composite structure diagrams
Feedback
(C) Copyright IBM Corporation 2004, 2005. All Rights Reserved.