Author Topic: Simple click->copy Add-in  (Read 9745 times)

zalbina

  • EA User
  • **
  • Posts: 149
  • Karma: +0/-0
    • View Profile
Re: Simple click->copy Add-in
« Reply #15 on: May 08, 2013, 05:36:54 pm »
The Clone() function inserts a copy of the package into the same parent as the original package. Returns the newly-created package.

I'm asking about copy/clone elements such a classes, attributes, connectors and ect.

Thanks.


qwerty

  • EA Guru
  • *****
  • Posts: 13584
  • Karma: +396/-301
  • I'm no guru at all
    • View Profile
Re: Simple click->copy Add-in
« Reply #16 on: May 08, 2013, 05:42:49 pm »
If the Clone does not return what you expect you have two choices: a) code it the way your expectations are fulfilled; b) ask Harry Potter to lend you his magic stick.

q.
« Last Edit: May 08, 2013, 05:44:21 pm by qwerty »

zalbina

  • EA User
  • **
  • Posts: 149
  • Karma: +0/-0
    • View Profile
Re: Simple click->copy Add-in
« Reply #17 on: May 08, 2013, 05:48:46 pm »
 ;D, did you mean nobody needs to copy/clone elements? Such a pitty :(.

qwerty

  • EA Guru
  • *****
  • Posts: 13584
  • Karma: +396/-301
  • I'm no guru at all
    • View Profile
Re: Simple click->copy Add-in
« Reply #18 on: May 08, 2013, 08:25:31 pm »
EA is targeted to support OO. So why in the world could someone have the idea that EAs API should be somehow OO, e.g. by providing a clone method not only for packages, but also for elements, diagram, etc.? Or to offer a Delete methods for all of them? Probably because nobody demands it (I asked the last question in the suggestions and got not a single response). And why is nobody asking for a strict OO API? I guess because people rather like GOTO and spaghetti code.

q.
« Last Edit: May 08, 2013, 10:07:32 pm by qwerty »

Geert Bellekens

  • EA Guru
  • *****
  • Posts: 13387
  • Karma: +566/-33
  • Make EA work for YOU!
    • View Profile
    • Enterprise Architect Consultant and Value Added Reseller
Re: Simple click->copy Add-in
« Reply #19 on: May 08, 2013, 09:20:09 pm »
Quote
I guess because people rather like GOTO and spaghetti code.
q.
Or people have given up asking for improvements, and just make due with what's available. :-/

Geert