I have created a custom MDG and within a model using that MDG defined a Template package to define how some elements appear. But depending on the metaclass of my stereotype elements are wrong...
What I was trying to do:
- Create a Stakeholder stereotype from the Actor metaclass
- Create a Stakeholder Group stereotype from the Actor metaclass (a second instance of the metaclass)
- Template the Stakeholder Group element in rectangle notation
- Create two custom diagrams, one with the Stakeholder in the toolbox and one with Stakeholder Group in the toolbox
What happens is that when I drop either a Stakeholder or a Stakeholder Group onto their respective diagrams that they appear in rectangular notation (correct for the Stakeholder Group, but not for the Stakeholder that should be appearing as a stick-man/person). Also, the Stakeholder is given two stereotypes - Stakeholder and Stakeholder Group.
Without the Template defined, the Stakeholder appears correctly, with only the Stakeholder stereotype.
As a test, I redefined Stakeholder Group to be derived from a UseCase metaclass (not because I want to but because it also has a rectangle notation option and I have another element that is derived from UseCase).
With this test, I can define my templated Stakeholder Group in rectangle notation, when I drop a Stakeholder on it's diagram it appears as a stick-person, a Stakeholder Group on it's diagram appears as a UseCase in rectangle notation and a Use Case on it's diagram appears as an oval UseCase. All I've done is to drag the Extension relationship from the Actor to the UseCase metaclass and EA behaves differently.
I would ideally like to treat the Stakeholder as an Actor (it is intended to be a group of Actors and in other diagrams may want to behave as an Actor for assigning relationships).
I cannot see anything I have done wrong - can anyone shed light on something I might have overlooked or a reason why EA behaves differently when assigning custom stereotypes and/or templates to an Actor?