This site uses cookies to deliver our services. By using this site, you acknowledge that you have read and understand our Cookie and Privacy policy. Your use of Kontext website is subject to this policy. Allow Cookies and Dismiss

VS2010新特性-Modeling Project-UML Component Diagram 组件图

377 views 0 comments last modified about 9 years ago Raymond Tang

组件图,又名构件图,展现了一组组件之间的组织和依赖,用于对源代码、可执行的发布、物理数据库和可调整的系统建模。

本文将介绍VS2010中的组件图 UML Component Diagram

一,新建组件图

选中ModelingProjectTest,右键|Add|New Item|Installed Templates|Modeling|UML Use Component Diagram,输入文件名称UMLComponentDiagramTest.componentdiagram,点击Add按钮,即建立了一个空的组件图。


二,组件图包含的内容

Toolbox工具箱中我们可以看到组件图可以包含如下内容:


Component

添加一个组件,这个组件是系统功能可重用的单元

Dependency

指定某一元素依赖于另一元素

Delegation

连接组件上的一个端口到它某一个部件的一个端口

Provided Interface

添加一个端口,这个端口用于向其它组件提供某一接口中定义的操作或者服务

Required Interface

添加一个端口,这个端口需要其他组件提供某一接口中定义的操作或者服务

Comment

添加备注

Generalization

指定某一组件从其它组件继承了特征和行为

Connector

创建元素之间的默认关系

Part Assembly

指定某一个组件内部的部件之间的连接

三,实现组件图

为本系列文章之前建立的各个项目建立一个简单的组件图,表示各个组件之间的关系,主要为依赖关系。


在上图中,WebApp组件依赖于CommonConfigData组件;Common组件依赖于ConfigData组件;DataProviders组件继承了Data组件的一些功能和行为且提供IWebAppDataProvider接口,而WebApp组件需要IWebAppDataProvider接口。

Related pages

ASP.NET Core 2 with Bootstrap 4 Bundler Minifier Issue: Expected semicolon or closing curly-brace found '-'

1005 views   1 comments last modified about 10 months ago

Background When upgrading Bootstrap to v4.0.0 release, the bundler and minifier doesn’t work properly due to CSS variable is commonly used: :root{--blue:#007bff; About 26 errors will show up in the Error List with the following message: ...

View detail

Migrate ASP.NET Core Projects – VS2015 to VS2017 and TFS2015 to TFS2017 Issues and Fixes

485 views   0 comments last modified about 2 years ago

Context Before Visual Studio 2017 was released, I was implementing my ASP.NET Core project using VS2015. TFS2015 is used for Continuous Build and Deployment for my projects. After migrating to VS2017, there are couple of issues I encountered in my environment: VS2017 has ...

View detail

Understand Code Dependencies with Visual Studio

612 views   0 comments last modified about 5 years ago

Visual Studio provides a convenient tool to generate visual code dependencies. It helps to identity circular references issues and also hubs. To learn more details about this function, visit ...

View detail

开始下载安装Visual Studio 11 Beta吧!

275 views   0 comments last modified about 7 years ago

  ...

View detail

Visual Studio 2011 New Features 新增特性汇总

285 views   0 comments last modified about 8 years ago

本文将介绍Visual Studio 11 Express for Windows Developer Preview中包含的新特性。

View detail

VS2010新增的IDE特性与功能之C#程序员篇

298 views   0 comments last modified about 9 years ago

注:本文参照MSDN博客C# FAQ的文章http://blogs.msdn.com/csharpfaq/archive/2010/05/10/new-ide-features-in-visual-studio-2010-for-c-developers.aspx;但不是完整翻译,而是提取主要内容以供大家参考,感谢原作者的奉献。一,Generate From Usage 从使用生成代码

View detail

Add comment

Please login first to add comments.  Log in New user?  Register

Comments (0)

No comments yet.