The composite structure diagram
The composite structure diagram allows the modeller to describe the relationships  between elements that work together within a classifier. It is similar to the class  diagram, but shows parts and connectors. The parts are not necessarily classes in  the model and they do not represent particular instances, but they may be roles that  classifiers may play.
The parts are shown in a similar manner to objects. The composite structure diagram  is used to show the runtime architectures of any kind of classifier.
Example:
graphic
In the following example, under UML1.x the modeller may have shown in a class diagram a typical  invoice with a header and detail as follows:
graphic
Although it is useful to be able to depict it as shown above, the significance of the invoice header  and detail may not have warranted separate class descriptions (Disclaimer. Only for example  purposes).  The composite structure diagram lends itself to describing, in this instance, the invoice  as follows:
graphic
From this we see the invoice modelled as a class and the header and detail modelled as parts. The  connector and its multiplicity indicate that a header will be a structural part of the invoice and that  one ore more detail parts will be present in an invoice.
The Composite Structure Diagram is also useful in displaying collaborations of classes as they, for  example will realize a use case. The notations used can be as follows:
Example: Collaboration with classes inside
graphic
Example: Collaboration connected to classes
graphic
An example of how the collaboration may be used:
graphic
For the use case:Capture customer, the Clerk will capture the customer, the customer address and  the related customer account. The composite structure diagram for this collaboration may look like  this:
graphic
To explicitly show the realization, the following diagram may be used:
graphic
 
Google
 
Web xpdian.com