VS .NET 类设计器

发布于 2024-08-02 19:50:00 字数 134 浏览 3 评论 0原文

假设Being 类具有Habitat 类型的属性。这两个类都在自己的 .cs 文件中实现。当我将两个类从类设计器拖放到新的类图上时,我没有看到从 Being 到 Habitat 的关联线,但在代码中存在关联。我做错了什么,或者这根本没有在 VS 中实现?

Assume that class Being has a property of type Habitat. Both classes are implemented in their own .cs files. When I drag and drop the two classes from the class designer onto a new Class diagram, I do not see an association line from Being to Habitat, whereas there is an association in code. Am I doing something wrong, or this simply isn't implemented in VS yet?

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(4

还给你自由 2024-08-09 19:50:01

要显示属性连接,请右键单击该属性; “显示为关联”或“显示为集合关联”(视情况而定)

To show the property connection, right-click on the property; "show as association" or "show as collection association" (as appropriate)

ζ澈沫 2024-08-09 19:50:01

默认情况下它是关闭的。右键单击该属性并选择“显示为关联”

It's off by default. Right click on the property and choose "Show as association"

瑾兮 2024-08-09 19:50:01

类图不显示类型的每个实例(属性)及其类型之间的“线”。这很快就会变得非常非常混乱。

如果“Being”源自“Habitat”(这没有意义),那么它会显示一条线。它显示继承行,而不是每个单独的字段/属性。

The class diagram doesn't show "lines" between every instance (property) of a type and its type. This would get very, very messy very quickly.

If "Being" derived from "Habitat" (which wouldn't make sense), it would show a line for that. It shows lines for inheritance, not each individual field/property.

埖埖迣鎅 2024-08-09 19:50:01

栖息地是存在的财产。它们并不像设计师所展示的那样关联。设计师彰显传承。

Habitat is a property in Being. They are not associated in the way the designer shows. The designer shows inheritance.

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文