troyal
troyal

Reputation: 2519

What does the '#' symbol mean in a UML class diagram?

I was reading Algorithms in a Nutshell (O'Reilly) and came across this symbol in a class diagram. My guess is that it means the member is protected, but I wanted to see if anyone knows for sure what it means.

Upvotes: 90

Views: 130729

Answers (5)

Volodymyr Mankivskyi
Volodymyr Mankivskyi

Reputation: 149

Add also to :

~ Indicates package-private (or default)

Upvotes: 14

matang
matang

Reputation: 259

'#' stands for visibility "protected" (similar to public,private ) behavior of the property/methods in the class . You can find more of the same at uml_basic_notations

Upvotes: 4

william.eyidi
william.eyidi

Reputation: 2365

It implies that it is protected, for a variable it will only be seen in the class and inherited classes.

Upvotes: 3

Jayden
Jayden

Reputation: 2778

'#' indicates the visibility. In this case it refers to a protected operation [ edited out the term 'method' as this is not as generic ].

Upvotes: 8

Mike Hofer
Mike Hofer

Reputation: 17012

It indicates a protected member of a class or other data type.

- Indicates private

+ Indicates public

# Indicates protected

Upvotes: 191

Related Questions