Book a Demo

Author Topic: class diagr: cntxt menu: 'insert related elements'  (Read 2732 times)

m1m1

  • EA Novice
  • *
  • Posts: 4
  • Karma: +0/-0
  • I love YaBB 1G - SP1!
    • View Profile
class diagr: cntxt menu: 'insert related elements'
« on: July 22, 2005, 02:34:28 am »
hi all,

i have trouble understanding the 'insert related elements' context menu entry in class diagrams.

example: this is the situation:
Code: [Select]

interface Type1
{
   public void doSomething(Type2 x);
}

interface Type2 {}

now i have added Type1 to a class diagram manually.
when i right-click 'insert related elements' in the context menu of Type1,
i would expect to see Type2 added, as there is a dependency  from Type1 to Type2.
But this does not work.
It seems that this feature only can insert types of attributes of classes as in:
Code: [Select]

class Type1
{
   private Type2 y;
}

is it a bug or a feature??

thanks a lot
regards
matthias


Eve

  • EA Administrator
  • EA Guru
  • *****
  • Posts: 8110
  • Karma: +119/-20
    • View Profile
Re: class diagr: cntxt menu: 'insert related eleme
« Reply #1 on: July 24, 2005, 03:30:38 pm »
Hello Matthias,

Yes, there is a dependency between those two elements.  However, the 'Insert related elements' functionality only uses connectors between different elements.  Until you add an explicit dependency connector it won't be detected.

Simon

m1m1

  • EA Novice
  • *
  • Posts: 4
  • Karma: +0/-0
  • I love YaBB 1G - SP1!
    • View Profile
Re: class diagr: cntxt menu: 'insert related eleme
« Reply #2 on: July 25, 2005, 01:38:49 am »
hello simon,

thanks for the answer.
i am afraid i don't quite understand yet though.
if you have to define an explicit connector first
what is the point in having it 'detected' by EA after that?
after all EA knows about dependencies
(caused return or argument types etc) so why can't they be added by 'insert related elements'.
what is the benefit of this feature then?

thanks
regards
matthias

Eve

  • EA Administrator
  • EA Guru
  • *****
  • Posts: 8110
  • Karma: +119/-20
    • View Profile
Re: class diagr: cntxt menu: 'insert related eleme
« Reply #3 on: July 25, 2005, 04:24:15 pm »
That functionality looks at the different connectors (and only connectors) between elements, and adds any elements that are joined by a connector to the current diagram.

EA doesn't automatically create a connector for every method return type or parameter classifier set.

Maybe the feature could be expanded to use these implicit relations, but at the moment our efforts are being put into other areas.

Simon

m1m1

  • EA Novice
  • *
  • Posts: 4
  • Karma: +0/-0
  • I love YaBB 1G - SP1!
    • View Profile
Re: class diagr: cntxt menu: 'insert related eleme
« Reply #4 on: July 25, 2005, 10:20:27 pm »
hello simon,

thanks for the answer.
a bit disappointing but at least the issue is clearer now.

regards
matthias