Sparx Systems Forum

Enterprise Architect => Bugs and Issues => Topic started by: qwerty on November 02, 2021, 03:26:18 am

Title: Single metarelationship or none
Post by: qwerty on November 02, 2021, 03:26:18 am
Here's another strange one: I have the _HideUml.. set for the metaclass (being Class) of a stereotype. So it does not show any QL entries. Fine.

I add a metarelationship NoteLink and the Note is in the selection list for creation and nothing when dragging over an existing element/package. Also fine.

I add a Dependency towards the metaclass and now it's getting strange. The creation selection still shows just Note (hmmm). Further when I drag over a Class or Package the selection now offers Abstraction, Dependency, Realization and Usage. Why isn't it just Dependency? And why doesn't the creation list Class?

q.
Title: Re: Single metarelationship or none
Post by: Eve on November 03, 2021, 08:49:02 am
Abstraction, Realization and Usage are specializations of Dependency, so they are inheriting the rule that you created.

Dependency isn't offered when creating a new element because it targets everything and results is extremely unwieldy menus.
Title: Re: Single metarelationship or none
Post by: Paolo F Cantoni on November 03, 2021, 09:08:04 am
Abstraction, Realization and Usage are specializations of Dependency, so they are inheriting the rule that you created.

Dependency isn't offered when creating a new element because it targets everything and results is extremely unwieldy menus.
Thanks for the clarification, Eve.


Is this noted anywhere in the documentation?  I think it would be useful, if not alreadyavailable.


Paolo
Title: Re: Single metarelationship or none
Post by: qwerty on November 03, 2021, 09:19:06 am
Yes, that would be really helpful. I just consulted the UML specs and saw (after a bit of searching) that the are all speciaization of Dependency. Things you did not know...

q.
Title: Re: Single metarelationship or none
Post by: Eve on November 03, 2021, 09:49:26 am
I'm not going to try to document what UML metaclasses are specializations of each other in our help. If you want that information you need to reference the UML specification itself. Other than that, the first point is that this function works exactly the same for UML metaclasses as it does for your stereotypes. More succinctly... It works.

I can add information about the common UML connectors  and how you can define the same for your connector types to:
Metamodel Constraints and the Quick Linker (https://sparxsystems.com/enterprise_architect_user_guide/16.0/modeling/metamodel_constraints_quicklinker.html)

Rule Filtering
The metamodel constraints primarily define what connections are valid. The quicklinker is built from these valid relationships and is then filtered in a number of ways in order to present the relevant relationships to the user.
ItemDetail
Toolbox FilteringBy default for all new diagrams the elements and relationships offered by the quicklinker are restricted to match the types available in the toolbox.

This can be changed by the user on a diagram by selecting the Complete view for the diagram or unchecking the Filter to Toolbox option within the quicklinker menu.
Common RelationshipsRelationships defined with the _IsCommon property will not be offered as suggestions when a new element also needs to be created.

The following UML relationships include this behavior when they are used with a metarelationship:
  • Abtraction
  • Dependency
  • InformationFlow
  • Realization
  • Usage

Edit: I've also added _IsCommon to Special Attributes (https://sparxsystems.com/enterprise_architect_user_guide/16.0/modeling/supportedattributes_2.html).
Title: Re: Single metarelationship or none
Post by: qwerty on November 03, 2021, 08:13:52 pm
Oh, interesting. I peeked that sciptlet passage. I shall have to look into that once I've set foot here with the metaconstraints (and after the official release of 16 has been settled a while). Honestly, the metaconstraints appear to be a good piece of work, though as usual Sparx did not make it easy to get there. Still stumbling as you might have noticed in my other threads. (I seem to remember Paolo having said almost the same in tha longer thread a while ago.)

q.