gpt4 book ai didi

visual-studio-2008 - 使用 Visual Studio 2008 在类图中显示组合和依赖关系

转载 作者:行者123 更新时间:2023-12-02 00:42:07 26 4
gpt4 key购买 nike

我正在尝试使用 VS 2008 在类图中显示组合和依赖关系,但没有与上述关系关联的图表。请帮我解决这个问题。

最佳答案

Visual Studio 2010 Ultimate 支持组合、依赖和 UML 类图上的许多其他关系:

UML 类图:引用:http://msdn.microsoft.com/en-us/library/dd409437%28VS.100%29.aspx

UML class diagram

5: Association: A relationship between the members of two classifiers.

5a: Aggregation: An association representing a shared ownership relationship. TheAggregation property of the owner role is set to Shared.

5b: Composition: An association representing a whole-part relationship. The Aggregationproperty of the owner role is set to Composite.

9: Generalization: The specific classifier inherits part of its definition from the generalclassifier. The general classifier is at the arrow end of the connector. Attributes, associations, andoperations are inherited by the specific classifier. Use the Inheritance tool to create ageneralization between two classifiers.

alt text

13: Import: A relationship between packages, indicating that onepackage includes all the definitions of another.

14: Dependency: The definition or implementation of the dependent classifier might change ifthe classifier at the arrowhead end is changed.

alt text

15: Realization: The class implements the operations and attributes defined by the interface.Use the Inheritance tool to create a realization between a class and an interface.

16: Realization: An alternative presentation of the same relationship. The label on thelollipop symbol identifies the interface.

UML 类图:指南:http://msdn.microsoft.com/en-us/library/dd409416%28VS.100%29.aspx

Properties of an Association

Aggregation: This appears as a diamond shape at one end of the connector. You can use it toindicate that instances at the aggregating role own or contain instances of the other.

Is Navigable: If true for only one role, an arrow appears in the navigable direction. You can usethis to indicate navigability of links and database relations in the software.


Generalization: Generalization means that the specializing or derived type inherits attributes,operations, and associations of the general or base type. The general type appears at the arrowheadend of the relationship.

Realization: Realization means that a class implements the attributes and operations specified bythe interface. The interface is at the arrow end of the connector.

如果您有更多问题,请告诉我。

关于visual-studio-2008 - 使用 Visual Studio 2008 在类图中显示组合和依赖关系,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/2264232/

26 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com