1

What should be written in the operations compartment? Shall it contain function definitions and/or function calls?

Also, how to represent enum and structures in class diagram?

qwerty_so
  • 35,448
  • 8
  • 62
  • 86
Ashok
  • 119
  • 1
  • 3
  • 9

1 Answers1

5

Class diagrams operational block contains operations to classes and interfaces. It must be function definition and not function call. For enum representation in class diagram refer to UML class diagram enum

Community
  • 1
  • 1
AsthaUndefined
  • 1,111
  • 1
  • 11
  • 24
  • can you explain how to find which functions are performing operations to interfaces – Ashok Jan 24 '17 at 09:17
  • yes I have a source code in C++, I just designed UML class diagram using star UML tool. I want to know how to find and draw the interfaces in that class diagram – Ashok Jan 24 '17 at 09:46
  • An interface must have at least one class to implement it. In UML, an interface is considered to be a specialization of a class modeling element. Therefore, an interface is drawn just like a class, but the top compartment of the rectangle also has the text "«interface»". Something like: – AsthaUndefined Jan 24 '17 at 10:04