Legacy Issue Number: 14977
Source: Model Driven Solutions ( Steve Cook)
What’s our position about matching subsetting across association ends? I’m looking, for example, at the property Extend::Extension. This subsets source; but its other end subsets ownedMember. This clearly implies that Extend::Extension also subsets namespace (and owner); and the ownerMember end should also subset ownedElement.
There are plenty of examples of this all over the spec.
It would be nice to get this right for 2.4. Is this something we’ve already identified?
Reported: UML 2.3 — Thu, 14 Jan 2010 05:00 GMT
Disposition: Resolved — UML 2.4
The following OCL query is designed to find all associations that have asymmetric subsetting of their association ends:
For the UML 2.4 metamodel created from the UML 2.3 metamodel, this query found 182 cases of asymmetric subsetting.
Here is a proof that subsetting is symmetric (refer to fig 16.2 for the example, but the proof applies to any example):
Consider UseCase u and Extend e, such that u ? e.extension.
Then e ? u.extend [because of association invariant: c2 ? c1.p implies c1 ? c2.(p.opposite)]
It is given that e ? u.ownedMember [ because extend subsets ownedMember ]
Therefore u ? e.namespace [ because of association invariant ]
Hence u ? e.extension implies u ? e.namespace, i.e. extension subsets namespace.
For a redefined association end, the redefinition means that the same set of links are traversed by the redefining property as the redefined property. The same set of links is a special case of subsetting, and the argument then follows as for subsetting. (See 14993 which is resolved as a duplicate of this).
Where classes and associations have needed to be copied down into a package in order to enable these changes, it has been done. We minimize changes to the current specification diagrams and text by applying the following rules:
- Where a subsetted property is owned by an association, it is not shown in either diagram or text.
- Where a subset constraint can be deduced, it does not need to be shown in the diagrams or text.
- Redundant subsetted properties whose presence can be inferred from others, that are currently in the diagrams and/or text, are left there.
We anticipate that a future version of UML may apply different conventions to its diagrams to make it simpler to reason about property subsetting.
The vast majority of the changes involved in this resolution only occur in the metamodel and XMI, where missing subset constraints have been introduced.
In a few cases documented in this resolution, changes are needed to the diagrams and text to show where metaclasses and/or associations are introduced into a package to make the model merge correctly. Changes are also needed to the diagrams and text wherever a material “subsets” statement is absent.
Updated: Fri, 6 Mar 2015 20:58 GMT