Book a Demo

Author Topic: Virtual functions in Class diagrams  (Read 6914 times)

Shreyansh

  • EA Novice
  • *
  • Posts: 9
  • Karma: +0/-0
    • View Profile
Virtual functions in Class diagrams
« on: December 16, 2008, 05:48:54 pm »
Hi,

I am designing class diagrams in EA. My question is how to create a function in EA having both virtual and protected access modifier simultaneously.

Shreyansh Doshi

piotr.stankiewicz

  • EA Novice
  • *
  • Posts: 4
  • Karma: +0/-0
    • View Profile
Re: Virtual functions in Class diagrams
« Reply #1 on: December 17, 2008, 12:14:35 am »
When you click on operation name, you have two idnependent control items: one for chosing public/protected/private and one for chosing abstract (java) or virtual (C++) depening on chosen language for your model.

Shreyansh

  • EA Novice
  • *
  • Posts: 9
  • Karma: +0/-0
    • View Profile
Re: Virtual functions in Class diagrams
« Reply #2 on: December 17, 2008, 03:44:29 pm »
My language is C# and only abstract option is available for operation. There is no way to define virtual for C#.


KP

  • EA Administrator
  • EA Expert
  • *****
  • Posts: 2919
  • Karma: +55/-3
    • View Profile
Re: Virtual functions in Class diagrams
« Reply #3 on: December 17, 2008, 03:55:15 pm »
The usual approach to answering such questions is to try reverse engineering some code and see what EA makes of it. I haven't tried it myself, but from reading this page in the help I suspect that EA will create a tagged value named "virtual" for the operation.
The Sparx Team
[email protected]

Eve

  • EA Administrator
  • EA Guru
  • *****
  • Posts: 8110
  • Karma: +119/-20
    • View Profile
Re: Virtual functions in Class diagrams
« Reply #4 on: December 18, 2008, 09:12:13 am »
There is also a button "Advanced" that allows for setting various language specific properties of methods.

Virtual should be in that list for C#.

Shreyansh

  • EA Novice
  • *
  • Posts: 9
  • Karma: +0/-0
    • View Profile
Re: Virtual functions in Class diagrams
« Reply #5 on: December 18, 2008, 03:50:37 pm »
Yes Simon virtual option is available "Advanced" list.
Is it possible to add more keyword in this list.