The graphical editor dedicated to the Component Diagram has been specified from the UML 2.0 Superstructure Specification document. Feel free to bring your own remarks about the way UML concepts were represented in this diagram : we could discuss about that on the user mailing list .
1. Creation of the diagram
1.1. From the wizard
You can use the creation wizard to create a new component diagram. Select the corresponding Template to initialize the model.
The root element of the UML model is a Model and it contains a Package that also contains a Component as its children element. The diagram is then linked with the Component.
1.2. From an existing diagram
The activity diagram is necessarily associated with a Component model object.
Then you can create a new diagram by selecting a Component node in the Outline : "
" and select " ".2. Editing of the Diagram
2.1. Basic editing
2.1.1. Component
A component represents a modular part of a system that encapsulates its contents and whose manifestation is replaceable within its environment.
2.1.2. Interface
A Component defines its behavior in terms of provided and required interfaces. As such, a component serves as a type whose conformance is defined by these provided and required interfaces.
You can create an Interface at the Component level, or drag'n'drop an existing one from the outline.
2.1.3. Port
A Port specify the services that a Component provides (offers) to its environment as well as the services that it expects (requires) of its environment.
You can create a Port in a Component. The Port representation will be attached to the nearest border of its containing Component. This functionality is not completely implemented as it is not possible to associate a Port with an Interface yet.
2.1.4. ComponentRealization
The ComponentRealization concept is specialized to define the Classifiers that realize the contract offered by a component in terms of its provided and required interfaces.
You can create a ComponentRealization link between two Components . The ComponentRealization model object will be created into the target Component.
2.1.5. InterfaceRealization and Usage
A Component has a number of provided and required Interfaces, that form the basis for wiring components together.
An InterfaceRealization link can be created between a Component and an Interface : we used to say that the Component has a provided Interface.
A Usage link can be created between a Component and an Interface : we used to say that the Component has a required Interface.
2.2. Advanced editing
2.2.1. Interface representations
At the creation, it will be represented with a circle and a label at the top. Then its representation will change depending on the links it is connected to :
2.2.2. Modelize a Required/Provided Interface
3. Diagram Example
_______________________________________
By Jacques LESCOT, Anyware Technologies
August, 31 2006