Since then I've asked myself if there isn't any UML-way to visualize domain-specific components. I know how this sounds like: UML is generic by its very nature but not domain-specific. But let's give it a try anyway.
Before starting I have have to explain one thing first: actifsource distinguish only between two types of relations: the own-relation and the use-relation. The own-relation defines a strong coupling. If A owns B, B must not exist without A. The use-relation on the other hand doesn't imply any life-time semantics.
As I explained in my blog Software Architecture and Components, domain-specific components are defined implicitly around the own-relations of their meta-model.
Looking at the UML Component Diagram we find out that relations between components are realized as delegation connectors which connects a port to an element of the component.
And now the interesting question: does every use-relation between components lead to a port?
To answer this question, lets have a look at the meta-model of a UML class. A class can be seen as a component as well, composing
- a name attribute
- member variables
- member functions
- own relation
- use relation
Before continuing the discussion, let's have a look at member functions. Functions consist of named and typed arguments. The types are modeled as a use-relation to other existing types.
So, what is the difference between the use-relation of member-variables to other types and the use-relation of typed arguments of a member function?
The use-relations of member-variables define the permanent relations between components while the use-relations of typed arguments of a function definition simply simply define a temporary relation.
Obviously we have to distinguish between two different of use-relations:
- use-relations which define permanent relations between components
- use-relations which define temporary relations between components
Permanent use-relations shall be shown as ports in a component diagram.In my next blog I try to explain how composite structures shall be visualized using the UML Composite Structure Diagram combined with the idea of ports for permanent use-relations.
No comments:
Post a Comment