Sparx Systems Forum

Enterprise Architect => Suggestions and Requests => Topic started by: Martin Terreni on April 08, 2008, 09:38:08 pm

Title: "copy diagram" feature
Post by: Martin Terreni on April 08, 2008, 09:38:08 pm
Right now the copy diagram feature seems to have two options:
1) shallow copy: CRTL+A in the source digarm and paste as link in new.
2) deep copy: recreate all the entities in the sourcedigarm in the new (inluded linked elements).

I would expect copy diagram to create an identical copy of the source, meaning deep copy but links should stay links.
An exact copy = doing exactly the same twice, not making it look the same in the diagram. I would expect EA to "recreate" the diagram the same way i did.

Another thing: It is only possible to create them within a pacakge , what if it was a diagram under a composit element I wanted to recreate under a new element?

thanks
Title: Re: "copy diagram" feature
Post by: Matt on April 11, 2008, 09:50:43 pm
Martin,

what are you trying to achieve with the copy diagram function?

For TA we needed the ability to copy elements to new diagrams so have added this feature.  You can select the elements you want either from the diagram or from the datagrid and select the multi-element move/copy feature.

It maintains all the links, allows you to select just the elements you want and much more...  basically it just adds the elements to the diagram and this can be anywhere in the project tree...

There will be a demo of this posted to the tutorials part of the TA site http://solutionsreality.com/products/timearchitect/tutorials.aspx over the weekend...

Best regards,

Matt
Title: Re: "copy diagram" feature
Post by: Martin Terreni on April 12, 2008, 06:40:24 pm
When coying I just would like EA to copy the actions I did:
1) If I had an instance \ invocation in the source diagram, I would like to have also a new  instance \ invocation of the same element in the target.
2) If I made a link to an element in the source diagram I would like to have the same link in the target.
3) if I had a connector in the source diagram I would like to have a parallel one in the target.
Title: Re: "copy diagram" feature
Post by: peter.zrnko on April 17, 2008, 01:50:11 am
Read this (http://www.sparxsystems.com.au/EAUserGuide/index.html?duplicateadiagram.htm). I think it will help you with copying the whole diagram.

It's not possible to achieve a copy of diagram in the usual manner - Ctrl+A Ctrl+C Ctrl+V. But there is a way to achieve it.
Title: Re: "copy diagram" feature
Post by: Martin Terreni on April 18, 2008, 02:14:14 am
Nope, this is the problematic functionality. It creates a new element for any linked element.
Title: Re: "copy diagram" feature
Post by: hanrahan99 on April 23, 2008, 11:04:39 pm
Is there a way to do a "Deep Copy" of any diagram from Project "A" and paste it into Project "B"?
Title: Re: "copy diagram" feature
Post by: «Midnight» on April 24, 2008, 01:29:35 am
I don't think so, but you could try. Just make sure both projects are open throughout the entire time.

Otherwise you'll have to do an XMI export and import cycle.
Title: Re: "copy diagram" feature
Post by: hanrahan99 on April 24, 2008, 03:20:35 am
THANKS
Title: Re: "copy diagram" feature
Post by: peter.zrnko on April 24, 2008, 07:32:36 pm
When copying a diagram it could be nice to have these possibilities:
- shallow
- package
- deep

The new option "package" should work in such way that for every element on the copied diagram it will
- duplicate it, if it's in the same branch in the project as the copied diagram (all links to to this element will be also duplicated)
- display it on the new diagram as link to the original element
Visibility of all links will be the same as in original diagram.

There could be other ways how to specify which elements should be deep copied and which shallow copied. I think the package criterion is simple and would be useful.