Book a Demo

Author Topic: cool class diagram feature: how'd I do it?  (Read 3947 times)

brownale2k

  • EA Novice
  • *
  • Posts: 6
  • Karma: +0/-0
    • View Profile
cool class diagram feature: how'd I do it?
« on: March 16, 2006, 02:35:48 pm »
Somehow I activated something cool in a class diagram that I would really like to reproduce:  realized methods in a class diagram are listed separately from other methods.

Scenario:
I have an interface class that defines a couple of methods.

I have several concrete classes that implement the above interface.  In each of the concrete classes, the implemented methods are listed at the bottom of the class under the word "interface".  I have turned on alphabetical method name listing, so normally I just see all methods in one list.  But now, these cool concrete classes have local methods alphabetized at the top of the methods list, the word "interface", and then an alphabetized list of realized methods.  

Does anyone know what this is called, or better yet, how I enabled this?  Did I set something on the interface class so that it implementing classes would display realized methods separately? (I have other interfaces on the same diagram, but their concrete classes don't have the interfaces in a separate list.)

Methods shown in concrete class:
---------------------------------------------
+  myMethod1(int): int
+  myMethod2(String) : int
interface
+  theImplementedMethod(int) : int
+  theSecondImplementedMethod(String): String

Any ideas what this is called or how I can do it again?   Thanks!

Eve

  • EA Administrator
  • EA Guru
  • *****
  • Posts: 8110
  • Karma: +119/-20
    • View Profile
Re: cool class diagram feature: how'd I do it?
« Reply #1 on: March 16, 2006, 02:39:20 pm »
My guess is that you also have stereotype grouping turned on (Tools | Options | Objects | Group Operations by Stereotype) and the two implemented methods have the stereotype "interface".

brownale2k

  • EA Novice
  • *
  • Posts: 6
  • Karma: +0/-0
    • View Profile
Re: cool class diagram feature: how'd I do it?
« Reply #2 on: March 17, 2006, 06:40:08 am »
I do indeed have stereotype grouping turned on, but my two implemented methods do not have a stereotype of interface.  (Only the interface itself has a stereotype of interface.)

The only difference I can see is that one inteface class has a keyword of "Interface" and the other does not.

I tried typing in "Interface" in they keyword field of the other interface, but it had no effect.  I'm not sure where the keyword "Interface" came from or how it got there.
Again, thanks for any other suggestions about how to reproduce this cool effect....

Jos Fries

  • EA User
  • **
  • Posts: 20
  • Karma: +0/-0
    • View Profile
Re: cool class diagram feature: how'd I do it?
« Reply #3 on: March 31, 2006, 01:40:54 am »
Did you by any chance create a generalization relationship from the concrete class to the interface class (i.e. the concrete class inherits from the interface class)?

This relationship can only be drawn when "strict UML syntax" is off but then produces the result you described?

Regards,

Jos

SF_lt

  • EA User
  • **
  • Posts: 216
  • Karma: +1/-0
  • The Truth Is Out There
    • View Profile
Re: cool class diagram feature: how'd I do it?
« Reply #4 on: April 04, 2006, 04:20:33 pm »
Quote
My guess is that you also have stereotype grouping turned on (Tools | Options | Objects | Group Operations by Stereotype) and the two implemented methods have the stereotype "interface".


yeah, I bet, that there is a better place for this option than Objects window - appearance or smth in this style  ;D
registertm everything to SparX

Eve

  • EA Administrator
  • EA Guru
  • *****
  • Posts: 8110
  • Karma: +119/-20
    • View Profile
Re: cool class diagram feature: how'd I do it?
« Reply #5 on: April 04, 2006, 07:21:21 pm »
Quote
Did you by any chance create a generalization relationship from the concrete class to the interface class (i.e. the concrete class inherits from the interface class)?

This results in grouping, but it would look different to the effect described.  Something like the following.

Methods shown in concrete class:
---------------------------------------------
+  myMethod1(int): int
+  myMethod2(String) : int
 ::MyInterfaceName
+  theImplementedMethod(int) : int
+  theSecondImplementedMethod(String): String