Sparx Systems Forum
Enterprise Architect => Automation Interface, Add-Ins and Tools => Topic started by: mexfollower on January 20, 2008, 09:23:17 am
-
Hi all,
I have been using EA for some time now, but there is a point which still gets me very confused ???. It is the possibility to create two elements with the same name in a package.
What is the interest of such a possibility? I don't recall to have seen it in competitive products.
I find this possibility very time wasting. At times, and for several reasons (mistakes, reordering of package content...) I find several items with the same name in a package. I then have to undertand what happens and to correct it which, as I find the problem long after it happened, may be tricky (lately, two classes with the same name were mapped to the same code class).
Is there a way to have EA force unicity of names in a given package?
Do you plan to have this in your future releases of EA?
Meanwhile, is there a workaround?
-
EA seems to identify items by GUID rather than name.
I suppose you could use the GUID as the name, then put your 'friendly' name in the Alias field. Not perfect by a long shot. And you'd need some kind of (simple) add-in to get the GUID into the name field.
-
...What is the interest of such a possibility? I don't recall to have seen it in competitive products.
...
Again: EAUI. I know that Rose warns against duplicate name usage (and it could be turned off). But AFAIR (many years since my last Rose touch) it was also possible to live with multiple elements with same name.
-
EA seems to identify items by GUID rather than name.
I believe so. But so does Rose which, in the end, include a unicity control.
I suppose you could use the GUID as the name, then put your 'friendly' name in the Alias field. Not perfect by a long shot. And you'd need some kind of (simple) add-in to get the GUID into the name field.
This is quite interesting. Could you give me more informations about such add-ins : how they work and how to build them?
As you say, this may be not the final solution (it means the name of the classes would have a GUID instead of a 'user friendly' name, which is not ideal from a developer point of view but it's a start).
-
Again: EAUI. I know that Rose warns against duplicate name usage (and it could be turned off). But AFAIR (many years since my last Rose touch) it was also possible to live with multiple elements with same name.
It may be so (I haven't used Rose lately either) as Rose uses GUID, but at least duplicates are checked.
Duplicate names are not a good thing to me. Let me explain.
I see two groups of UML editors.
The first group targets UML designers. They respect UML notations and are flexible (allow creation of UML profiles for example). Rose and StarUML are in this group.
The second group targets UML developers. They are 'close to code' : they are often integrated with an IDE (Eclipse or VS) and have good round tripping capabilities. Omondo and Visual paradigm are good examples.
Try to build a sequence diagram in which an object sends a message to an actor. This makes sense from a designer point of view (the system interacts with the actor). But it means nothing for a developer has he can't create an 'actor class' to put the operation called by the message.
I see UML modeling software moving towards the second group, closer to code (IBM shift from Rose to RSA is a good example of this trend).
If so, UML element names should be identical to code elements names (class names). This avoids mistakes and eases code generation. On the other side EA use of GUIDs adds complexity and requires a mapping step between model and code before generation.
Duplicate name control would be a major improvement to such a good modeling product.