Sparx Systems Forum
Enterprise Architect => Automation Interface, Add-Ins and Tools => Topic started by: José on September 15, 2015, 06:13:28 pm
-
We want to put a lot (>1000) of requirements into our Enterprise Architect model. But these requirements do not yet have an unique identifier in EA, which is required. We do not want to give each requirement this ID by hand. Is there a way to auto-generate this ID for all these items in once?
I was thinking that maybe this might already be standard EA functionality. If not, could we otherwise use the scripting functionality?
I hoped to find some information on this online (user community/forum) but I was not able to. Does anyone have any suggestions/examples how they do it within there organisation?
Kind regards, José
-
José,
As soon as you import the requirements in EA they automatically get their unique ID (GUID).
Geert
-
Hi Geert,
I know that, but that's not what I meant. There is also the 'alias' field in which you can give the requirement a name like 'STK-001' or 'US-001' or whatever is determined within the organisation, which is visible for all EA users in your model. I was wondering if there is a way to get this field automatically filled with some value. We then can start referring to this alias in our documents so that everyone knows exactly about which requirement we are talking.
Hopefully this clarifies my question.
Kind regards, José
-
Hi José,
No, there's nothing standard in EA that will fill in the Alias for you.
There are auto-naming features, but as far as I know they will only fill in the name, and not the alias.
[highlight]See qwerty's answer :-[[/highlight]
The upside is that writing a script to assign each requirement a unique ID and store that in the alias is a trivial task.
Geert
-
Auto-name has settings for both name and alias.
q.
-
Thank you to both... That's indeed what I am looking for.
Kind regards, José
-
Be aware that EA has internal counter, so when you create an element it will be given the next id, let's say REQ-026. When you will delete that element from model, next time you will create new element, EA will give it REQ-027 even though REQ-026 no longer exists.
-
I would regard this an issue since requirements do not necessarily have to be numbered consecutive. But (!) EA does not check the uniqueness of the identifiers. Can happen easily that a manual change will produce duplicates. One would need some script/add-in to check for consistent naming.
q.
-
That's an coincidence, I was thinking about adding such feature to my addin (http://www.sparxsystems.com/cgi-bin/yabb/YaBB.cgi?num=1442230343) today. This should be fairly easy to implement.
The second advantage could be support for many projects in one repository, where each project should have its own numbering. Right now EA does not support that, as far as I know.
-
No, EA doesn't. But it provides means to enable add-in developers to do so :-)
q.