Author Topic: Improve the generation of MDG Technologies  (Read 331 times)

Guillaume

  • EA User
  • **
  • Posts: 720
  • Karma: +21/-0
    • View Profile
    • www.umlchannel.com
Improve the generation of MDG Technologies
« on: April 11, 2019, 11:43:00 pm »
When I use an MTS file to generate the MDG Technology, it is convenient as it stores the previous selection (profiles, searches...)
It would be nice to have an option to automatically regenerate the UML Profiles (XML files) provided EA stores the source package in the XML.

It would save so much time not having to export each profile to the separate XML file.

I'm not sure this is feasible using the API as a workaround.
Guillaume

Blog: www.umlchannel.com | Free utilities addin: www.eautils.com


PeterHeintz

  • EA User
  • **
  • Posts: 784
  • Karma: +46/-17
    • View Profile
Re: Improve the generation of MDG Technologies
« Reply #1 on: April 12, 2019, 12:27:53 am »
10+
API can currently not be used as a work around. I inserted a similar post some time ago.
Best regards,

Peter Heintz

Geert Bellekens

  • EA Guru
  • *****
  • Posts: 9100
  • Karma: +239/-27
  • Make EA work for YOU!
    • View Profile
    • Enterprise Architect Consultant and Value Added Reseller
Re: Improve the generation of MDG Technologies
« Reply #2 on: April 12, 2019, 12:42:43 am »
10+
API can currently not be used as a work around. I inserted a similar post some time ago.
It can't? I thought I saw some new functions that allowed generated the MDG yourself. Is there still something missing?

I was planning to one day write a script to automation the complete MDG creation;

Geert

PeterHeintz

  • EA User
  • **
  • Posts: 784
  • Karma: +46/-17
    • View Profile
Re: Improve the generation of MDG Technologies
« Reply #3 on: April 12, 2019, 01:04:50 am »
This plan I had as well.
For V14 I am not 100% sure, but I let a student of mine check it, and he stated that the API still misses the features needed.
Best regards,

Peter Heintz

Aaron B

  • EA Administrator
  • EA User
  • *****
  • Posts: 914
  • Karma: +14/-0
    • View Profile
Re: Improve the generation of MDG Technologies
« Reply #4 on: April 12, 2019, 09:56:50 am »
You should be able to use the SavePackageAsUMLProfile and GenerateMDGTechnology methods on the Repository class to help automate building of your Technologies.
https://sparxsystems.com/enterprise_architect_user_guide/14.0/automation/repository3.html

As a basic example without any error checking...

Code: [Select]
//This script requires EA 14 or higher

var TECHNOLOGY_DIR = "C:\\Projects\\EA\\Technologies\\MyTechnology\\";

Repository.SavePackageAsUMLProfile("{725910FA-1F0C-47c9-9A36-0F138D3BE653}", TECHNOLOGY_DIR + "MyStereotypes.xml");
Repository.SavePackageAsUMLProfile("{00C6AF6F-2B28-4afb-9491-B8458FE94C8C}", TECHNOLOGY_DIR + "MyDiagrams.xml");
Repository.SavePackageAsUMLProfile("{9E5DB294-8505-4f33-8639-2728A21B4FE4}", TECHNOLOGY_DIR + "MyToolbox.xml");
Repository.GenerateMDGTechnology(TECHNOLOGY_DIR + "MyTechnology.mts");