Sparx Systems Forum
Enterprise Architect => General Board => Topic started by: Jayson on February 15, 2021, 12:08:14 pm
-
Hey all
On my question to uncover the darkest recesses of Sparx, I am wondering each stereotype has ONE set of tagged values but MULTIPLE sets of the same tag groups repeated for each metatype.
If you look at the XML export that the MDG generator produces, the tagged values are directly under the <Stereotype> tag whereas the tag groups are embeded in <Property> elements of each <Apply> element.
If you look at each individual <Apply> element i.e <Apply type=Association"> & <Apply type="Class"> you see that the tag groups are repeated under each one.
What am I missing?
Cheers
Jays :-)
-
I'm out here since I don't touch any of EA's bells unless being force to. I only once used these groups and already forgot why and where. It's always the same: you see a nice feature and once you start using it you drown in a swamp of "does not work as expected" :-/
q.
-
Groupings work fine for me (only on elements)
A bit cumbersome to set up, but it is a nice way to structure tagged values.
I whish they would support it for attributes and connectors as well.
Geert
-
Hey Geert
But am I correct in my assumption that you can only specify a SINGLE set of tagged values for a stereotype rather than a set of tagged values per metatype?
If so, then why does the tag grouping repeat itself under each <Apply>? Especially since the content is the same in each case.
Cheers :-)
-
Yes, it's the same stereotype with the the same set of tagged values regardless of how many metatypes it can be applied to.
You can however choose to present those tagged values with a different grouping based on the metatype.
-
Thanks for that Eve!
Does the Profile Helper support this? If so how as it appears as if it only supports creating a single set of tag groupings.
Cheers :-)
-
Yes, it's the same stereotype with the the same set of tagged values regardless of how many metatypes it can be applied to.
You can however choose to present those tagged values with a different grouping based on the metatype.
Hey Eve
So I tried to get two different metaclasses belonging to the same stereotype to have two different sets of groupings by directly manipulating the XML (see below) but no matter what I do Sparx only shows one set of groups (the one defined in Class).
Wassup? Am I doing something wrong or did I misunderstand what you were saying?
Cheers :-)
<AppliesTo>
<Apply type="Actor">
<Property name="_tagGroupings" value="T2=G1;T1=G1;T4=G2;T3=G2;"/>
<Property name="_tagGroups" value="G1,G2"/>
</Apply>
<Apply type="Class">
<Property name="isActive" value=""/>
<Property name="_HideUmlLinks" value="True"/>
<Property name="_tagGroupings" value="T2=G3;T1=G3;T4=G4;T3=G4;"/>
<Property name="_tagGroups" value="G3,G4"/>
</Apply>
</AppliesTo>
<TaggedValues>
<Tag name="T1" type="" description="" unit="" values="" default=""/>
<Tag name="T2" type="" description="" unit="" values="" default=""/>
<Tag name="T3" type="" description="" unit="" values="" default=""/>
<Tag name="T4" type="" description="" unit="" values="" default=""/>
<Tag name="T5" type="" description="" unit="" values="" default=""/>
</TaggedValues>
-
Eeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeve?
Do you have any ideas on this?
Cheers :-)
-
Righto! After much experimentation I have reached the following conclusions:
1. You CANNOT have different tag groupings for the different metatypes belonging to the same Stereotype.
2. If you have multiple assignments of a tagged value to a tag group, then the last assignment (as per the order in the XML file) applies.
For example, if you assign Tag1 to Group1 in the Actor metaclass but then assign Tag1 to Group2 in the Class metaclass then Tag1 will be assigned to Group2 for ALL METATYPES (This example assumes that the Class metaclass is the second definition in the XML file).
3. If you extend a Stereotype, you CAN re-define the tag groupings for this newly created Child Stereotype without affecting the base Stereotype. But once again, the same rule #1 applies to the Child Stereotype.
In order to re-assign the tag grouping in this manner, the Child Stereotype MUST extend an entirely different metaclass.
In short, this is all farking hideous!
I hope this helps SOMEONE out there.
Cheers
Jays :-)
-
Hi Jays,
If you haven't already please formally report this defect. Since nobody has said what you're trying to do is non-sense, it fair to call it a defect.
I've reported issues with multiple metaclass extensions also (not related to yours, but may be caused by the same root cause).
In the past, multiple "apply types" in an MDG seemed to work for Associations and AssociationClasses (so not just cross metaclasses, but even cross metaclass types) but I'm beginning to suspect that may have been hardcoded and not generally extensible.
Anyway, many thanks for documenting the diagnoses. We waste enough time fighting EAUI without repeating the time lost by others.
Paolo
-
Hey champ
So Eve stated that tag groups are meant to function like this, so unless she was mistaken then yeah its mean to be there.
Quick question, HOW do I report a defect?
Cheers :-)
-
At the foot of the page you are staring at now, there are six columns of options. In the fifth column (purely by chance, not Freudian at all!) the third option is Report a Bug.
-
Awesome! Thanks for that.
Piss and moan submitted ;)