所以我看到了这个问题:In Java, difference between default, public, protected, and private并决定在我的域模型 (MVC) 中使用无修饰符
,但我无法理解如何将它们放入域模型图中?
根据Wikipedia :
"+" Public
"-" Private
"#" Protected
"/" Derived (can be combined with one of the others)
"_" Static
但是我不知道我应该在没有添加修饰符的字段中使用什么?
最佳答案
我相信“~”是默认修饰符的选择。
'~' : for package visibility
引用资料如下:
http://www.ibm.com/developerworks/rational/library/content/RationalEdge/sep04/bell/
关于java - 字段的 UML 域模型可见性,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/16885274/