Author Topic: Custom profile: Extending a Stereotype which extends a Metaclass  (Read 2654 times)

zaxxon

  • EA Novice
  • *
  • Posts: 2
  • Karma: +0/-0
    • View Profile
Custom profile: Extending a Stereotype which extends a Metaclass
« on: November 12, 2018, 11:54:51 pm »
Hello,

I've unsucsfully searched realted posts about this topic, so I expose the problem in case anyone has a response.

I created a custom profile Extending Requirement Metaclass with a custom stereotype, lets say MyRquirement. MyRequirement adds two tagged values with an enumerated type. Then. I wanted to extend MyRequirement with two Stereotypes (SoftwareRequirement and SystemRequirement) but it didn't worked when I imported the profile to my project. Lately, I realized that forcing these last stereotypes extending generic Requirement metaclass as well as Specializing Myrequirement solved that.

Is this the correct way to operate? When you make a stereotype hierarchy all the stereotypes need to extend a base metaclass? Or there is something i am doing wrong?

Thank you.

Geert Bellekens

  • EA Guru
  • *****
  • Posts: 13228
  • Karma: +551/-33
  • Make EA work for YOU!
    • View Profile
    • Enterprise Architect Consultant and Value Added Reseller
Re: Custom profile: Extending a Stereotype which extends a Metaclass
« Reply #1 on: November 13, 2018, 12:25:00 am »
Hi zaxxon,

To extend your stereotype with another more specific stereotype you should use a Generalization and not an Extend relation.
In v14 this should be enough.
In earlier versions you also needed to extend the metaclass from your sub-stereotype as well.

I have found however that I needed to do that in v14 as well, despite the claims from Sparx.

Geert

zaxxon

  • EA Novice
  • *
  • Posts: 2
  • Karma: +0/-0
    • View Profile
Re: Custom profile: Extending a Stereotype which extends a Metaclass
« Reply #2 on: November 13, 2018, 06:31:36 pm »
Thank You Geert,

This was precisely what I noticed, that when you create a more specific Stereotype you need both to extend the Requirements Metaclass and also use Generalization with the parent Stereotype. Since I still not migrated to v14 I suppose this is normal. I just wanted to confirm that this was the correct way to operate because I found that it worked by trial and error rather than reading it in any document.

Best Regards,