UML基本架构建模--图的通用建模技术(一)

Modeling Different Views of a System

建模系统的不同视图

When you model a system from different views, you are in effect constructing your system simultaneously from multiple dimensions. By choosing the right set of views, you set up a process that forces you to ask good questions about your system and to expose risks that need to be attacked. If you do a poor job of choosing these views or if you focus on one view at the expense of all others, you run the risk of hiding issues and deferring problems that will eventually destroy any chance of success.

当你从不同的视点为系统建模的时候,实际上是同时从多个维度上构建系统。通过选择正确的视图组建立一个过程,迫使你提出对系统有帮助的问题及免受不必要的攻击风险。如果你没有用心地选择这些视图或是在一张视图上花费太多的时间,隐藏问题和拖延问题产生的风险最终会破坏任何成功的机会。

To model a system from different views,

nDecide which views you need to best express the architecture of your system and to expose the technical risks to your project. The five views of an architecture described earlier are a good starting point.

nFor each of these views, decide which artifacts you need to create to capture the essential details of that view. For the most part, these artifacts will consist of various UML diagrams.

nAs part of your process planning, decide which of these diagrams you’ll want to put under some sort of formal or semi-formal control. These are the diagrams for which you’ll want to schedule reviews and to preserve as documentation for the project.

nAllow room for diagrams that are thrown away. Such transitory diagrams are still useful for exploring the implications of your decisions and for experimenting with changes.

从不同的视点建模系统要注意:

For example, if you are modeling a simple monolithic application that runs on a single machine, you might need only the following handful of diagrams.

Use case diagrams

Class diagrams (for structural modeling)

nInteraction view

Interaction diagrams (for behavioral modeling)

nImplementation view

Composite structure diagrams

nDeployment view

None required

举个例子,如果你正在建立一个运行在单个机器上的,简单且完整的应用模型,你只需要以下几个图:

用例图

类图(为结构建模)

协作图(为行为建模)

复合结构图

没有要求

If yours is a reactive system or if it focuses on process flow, you’ll probably want to include state diagrams and activity diagrams, respectively, to model your system’s behavior.

如果你构建的模型是反应系统或是侧重点是过程流,可能需要包含状态图和活动图来分别建模系统的行为。

Similarly, if yours is a client/server system, you’ll probably want to include component diagrams and deployment diagrams to model the physical details of your system.

同样地,,如果构建的是客户/服务系统,就需要包含组件图和部署图以为系统的物理情况建模。

Finally, if you are modeling a complex, distributed system, you’ll need to employ the full range of the UML’s diagrams in order to express the architecture of your system and the technical risks to your project, as in the following.

Use case diagrams

Sequence diagrams

Class diagrams (for structural modeling)

Interaction diagrams (for behavioral modeling)

State diagrams (for behavioral modeling)

Activity diagrams

nInteraction view

Interaction diagrams (for behavioral modeling)

nImplementation view

Class diagrams

Composite structure diagrams

nDeployment view

Deployment diagrams

最后,如果构建的是复杂的分布式系统模型,你需要为了表达系统的架构而采用全方位的UML图,也会在项目中引进下面的技术风险:

用例图

序列图

类图(为结构建模)

协作图(为行为建模)

状态图(为行为建模)

活动图

协作图(为行为建模)

类图

复合结构图

部署图

当明知不可挽回,唯一补偿的方法就是怀念,

UML基本架构建模--图的通用建模技术(一)

相关文章:

你感兴趣的文章:

标签云: