Book a Demo

Author Topic: Reuse model.  (Read 4752 times)

Juan Pablo

  • EA Novice
  • *
  • Posts: 5
  • Karma: +0/-0
    • View Profile
Reuse model.
« on: July 28, 2011, 04:21:12 am »
Hi:

How can i reuse a model, i.e. a secuence diagram. ?
Eventually i create a SD to represent an insert. Then i need to represent the update, delete. That's is the same with an othe method.
Could i Copy any way the diagram and reuse it regarding of not to change or override the original?

Thanks in advance
« Last Edit: July 28, 2011, 04:22:58 am by sepilrat »

Fabio Franco

  • EA Novice
  • *
  • Posts: 6
  • Karma: +0/-0
    • View Profile
Re: Reuse model.
« Reply #1 on: July 28, 2011, 06:45:21 am »
On the project browser (Alt+0), locate the diagram you need to copy. Right click it and on the context menu, select "Copy Diagram"

Then right click where in the project browser you want to copy the diagram to and on the context menu, select "Paste Diagram..."

The diagram will be pasted with the same name, but you can modify it in any way and it will not affect the original.

Is this what you're looking for?
Regards,
Fábio

Geert Bellekens

  • EA Guru
  • *****
  • Posts: 13523
  • Karma: +574/-33
  • Make EA work for YOU!
    • View Profile
    • Enterprise Architect Consultant and Value Added Reseller
Re: Reuse model.
« Reply #2 on: July 28, 2011, 05:21:56 pm »
Or you can use a diagram reference in another diagram.
This will show the contents of the original diagram in another diagram.

Geert

Fabio Franco

  • EA Novice
  • *
  • Posts: 6
  • Karma: +0/-0
    • View Profile
Re: Reuse model.
« Reply #3 on: July 28, 2011, 10:53:42 pm »
Do you mind sharing how that can be accomplished? I have diagrams that are the same in several parts of the project, but copying is not good because if something changes, the changes are not propagated to all copies and that's a problem.

The closest I could do to solve this problem was to create new diagrams and in each of them insert a link to the original/base diagram, it adds one extra step to see the desired diagram. Is there a better way to do this?

Geert Bellekens

  • EA Guru
  • *****
  • Posts: 13523
  • Karma: +574/-33
  • Make EA work for YOU!
    • View Profile
    • Enterprise Architect Consultant and Value Added Reseller
Re: Reuse model.
« Reply #4 on: July 29, 2011, 05:02:08 pm »
Drag/drop the diagram onto the other diagram and choose "diagram frame" as option.
That will show you the contents of the diagram right away.

Geert

Fabio Franco

  • EA Novice
  • *
  • Posts: 6
  • Karma: +0/-0
    • View Profile
Re: Reuse model.
« Reply #5 on: July 30, 2011, 06:45:03 am »
Thanks! That works!

jmdavidson

  • EA Novice
  • *
  • Posts: 1
  • Karma: +0/-0
    • View Profile
Re: Reuse model.
« Reply #6 on: August 19, 2011, 06:39:59 am »
Quote
On the project browser (Alt+0), locate the diagram you need to copy. Right click it and on the context menu, select "Copy Diagram"

Then right click where in the project browser you want to copy the diagram to and on the context menu, select "Paste Diagram..."
Thank you, Fábio.  This does just what I need.  I was concerned about the same thing you mentioned below, duplicating messages means more maintenance (or missed updates later.)

In fact, in examining the Relationships of the elements in the two diagrams I see that the messages are actually duplicated, which we want to avoid.

Evidence: Perform the Copy/Paste as above, then in one diagram rename one of the messages.  The same message in the other diagram is not also renamed.

Still searching then...

Best regards,
~Jeff
« Last Edit: August 19, 2011, 07:06:45 am by jmdavidson »

Eve

  • EA Administrator
  • EA Guru
  • *****
  • Posts: 8110
  • Karma: +119/-20
    • View Profile
Re: Reuse model.
« Reply #7 on: August 19, 2011, 08:38:37 am »
All sequence messages are unique to the diagram in EA. Therefore you will not find any method to re-use all or part of a diagram in another diagram without creating new messages.

OpenIT Solutions

  • EA User
  • **
  • Posts: 555
  • Karma: +9/-1
    • View Profile
Re: Reuse model.
« Reply #8 on: August 23, 2011, 02:12:50 am »
If you have a common flow in a sequence diagram that you want to reuse in several diagrams - a better approach might be to model the steps that are to be reused in their own sequence diagram(s) then add a sequence flow to the diagram....as Geert suggests drag and drop the newly created (sub) sequence diagram onto the main diagram and when prompted select "interaction occurance" then add your message flow to the newly created interaction occurance that will be on your main sequence diagram...

Regards,

Jon.