Many programming languages allow you to define class/instance methods, and the same for attributes. E.g. Python, Smalltalk. I have the concepts. E.g. for instance variables, every object has it’s own copy of the variables. Class variables only have one copy of the variables shared with all instances of the class.
My doubt is: how do I represent class methods and class attributes in UML? I was thinking in represent it through static, as in C++, Java, and C#, but is it ok? "static" and "class" are the same in UML?
Thanks!
Static attributes/operations1 need to be underlined. See also Class diagrams
1The term method is used for behavior (the howto) in UML. An operation is the term used in UML for a BehaviorialFeature that can be called on an interface (which is what you find in the compartment underneath the attributes).
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With