Author Topic: Adding tagged value types to stereotype  (Read 144 times)

rchalie

  • EA Novice
  • *
  • Posts: 14
  • Karma: +0/-0
    • View Profile
Adding tagged value types to stereotype
« on: January 14, 2021, 10:21:04 pm »
I'm seeking to add a few custom tagged value types to an existing (Archimate Capability in this specific case) stereotype, so that when I add a new element to the repository it automatically has the tagged value types (to avoid having to add them to each new element based on that stereotype).
The EA help/user guides are not really any help (as they tell you what you can do, but not how to do it).
Can anyone give me some directions as how to achieve this (so not just what to do, but also how to do that)?

T.i.a.

Rik van der Schalie
« Last Edit: January 15, 2021, 12:06:05 am by rchalie »

Geert Bellekens

  • EA Guru
  • *****
  • Posts: 10704
  • Karma: +375/-32
  • Make EA work for YOU!
    • View Profile
    • Enterprise Architect Consultant and Value Added Reseller
Re: Adding tagged value types to stereotype
« Reply #1 on: January 14, 2021, 10:39:35 pm »
Rik

Here's an example of how the UML profile should look like https://imgur.com/pbIRRRj

You then need to
- export the profile to xml
- include the profile in an MDG
- Import that profile in a model (or use one of the other ways to reference an MD)
- Set the profile to be the Active profile.

Now for every ArchiMate3::ArchiMate ApplicationComponent you will get a [yourProfile]::ArchiMate ApplicationComponent instead, with the added tagged values.

Geert

rchalie

  • EA Novice
  • *
  • Posts: 14
  • Karma: +0/-0
    • View Profile
Re: Adding tagged value types to stereotype
« Reply #2 on: January 15, 2021, 12:08:10 am »
Rik

Here's an example of how the UML profile should look like https://imgur.com/pbIRRRj

You then need to
- export the profile to xml
- include the profile in an MDG
- Import that profile in a model (or use one of the other ways to reference an MD)
- Set the profile to be the Active profile.

Now for every ArchiMate3::ArchiMate ApplicationComponent you will get a [yourProfile]::ArchiMate ApplicationComponent instead, with the added tagged values.

Geert

Hi Geert,

Thanks. One of my issues is how do I get to the relevant profile in the first place.The EA user guide may tell me I need to do that, it doesn't tell me how to get there.

Geert Bellekens

  • EA Guru
  • *****
  • Posts: 10704
  • Karma: +375/-32
  • Make EA work for YOU!
    • View Profile
    • Enterprise Architect Consultant and Value Added Reseller
Re: Adding tagged value types to stereotype
« Reply #3 on: January 15, 2021, 12:19:29 am »
You have to make your own profile.

You can create a profile package from the context menu Add Model Using Wizard | MDG Technology Builder | Basic Template

All of that is documented in https://www.sparxsystems.com/enterprise_architect_user_guide/15.2/modeling/mdgtechnologies_2.html

Geert

rchalie

  • EA Novice
  • *
  • Posts: 14
  • Karma: +0/-0
    • View Profile
Re: Adding tagged value types to stereotype
« Reply #4 on: January 15, 2021, 01:20:17 am »
You have to make your own profile.

You can create a profile package from the context menu Add Model Using Wizard | MDG Technology Builder | Basic Template

All of that is documented in https://www.sparxsystems.com/enterprise_architect_user_guide/15.2/modeling/mdgtechnologies_2.html

Geert

Am I correct in assuming that the result of this will need to be applied to each and every EA installation that will be working on the same repository? This is not something that you could apply once to a meta model in the repository, and then automatically have everybody use that. I see a governance nightmare ahead.

Geert Bellekens

  • EA Guru
  • *****
  • Posts: 10704
  • Karma: +375/-32
  • Make EA work for YOU!
    • View Profile
    • Enterprise Architect Consultant and Value Added Reseller
Re: Adding tagged value types to stereotype
« Reply #5 on: January 15, 2021, 01:25:16 am »
You can choose to import the MDG in the model, in the user's profile, or reference it from a central path (needs to be setup for each user)

I only use the import into model (all of my clients are using a central DBMS model)

Geert

Geert Bellekens

  • EA Guru
  • *****
  • Posts: 10704
  • Karma: +375/-32
  • Make EA work for YOU!
    • View Profile
    • Enterprise Architect Consultant and Value Added Reseller
Re: Adding tagged value types to stereotype
« Reply #6 on: January 15, 2021, 01:27:30 am »
"Set Active" has to be set for each individual user.

I wrote a little EA-Matic script to do it automatically on opening the repository

Code: [Select]
'[path=\Projects\EA-Matic Scripts]
'[group=EA-Matic]

option explicit

!INC Local Scripts.EAConstants-VBScript

'
' Script Name: ActivateTechnology
' Author: Geert Bellekens
' Purpose: Sets the given technology as the "Active" technology
' Date: 2020-03-31
'

function EA_FileOpen()
Repository.ActivateTechnology "MyTechnology"
end function

Geert