Enhancement
Major
Detail
Detail
Bugfix
Detail
#28011
Incorrect classification of association endings in compositions
If you create a composition A <>--->* B, the outgoing end (at A) of the underlying association is not marked as "to-1" (and also not as the aggregation end). This only happens if an explicit backreference is created for the composition reference. If the composition relationship is overwritten, the outgoing end is also classified incorrectly.
Data migration
Execute in the script console:
all(`tl.model:TLReference`) .filter(r -> $r.get(`tl.model:TLReference#composite`)) .map(r -> $r.get(`tl.model:TLReference#oppositeEnd`)) ..foreach(r -> $r.set(`tl.model:TLAssociationEnd#multiple`, false)) ..foreach(r -> $r.set(`tl.model:TLAssociationEnd#aggregate`, true))
Fixes the problem only for the current model, not for historical states.
Test
- /com.top_logic.demo/src/test/java/test/com/top_logic/demo/scripted/model/TestAssociationEndProperties.script.xml