UML规范阅读指导

Posted on Thu 22 December 2011 in 我用(IT)

今年八月OMG发布了UML 2.4.1 规范。观察规范的发布速度,作为软件开发领域内最最权威的建模语言可以当得起“与时俱进”四个字。

作为一个软件从业者,使用UML也有好多个年头了,不看看原版Spec显得实在不够 Professional,让我们打开下面这个链接,开始阅读UML规范的学习之路吧。 http://www.omg.org/spec/UML/2.4.1/

规范概览

从UML 2.0开始, UML规范被拆分成两个部分:基础结构规范(Infrastructure)和上层结构规范(Superstructure)。

基础结构规范定义了构成UML语言的基础;上层结构规范完善基础结构规范,定义了用户要使用的东西。这两部分规范构成了完整的 UML 2 规范。

UML的目标

基础结构规范是UML工具开发商们关注的,上层结构规范是我们这些UML真正用户关心的。翻开Superstructure第一章Scope我们可以看到如下文字

The objective of UML is to provide system architects, software engineers, and software developers with tools for analysis, design, and implementation of software-based systems as well as for modeling business and similar processes. UML的目标是提供给系统架构师、软件工程师和开发者一个分析、设计和实现软件系统的建模工具。

如何阅读规范?

见6.4 How to Read this Specification,里面又把规范分成了三个部分:

Subpart I: Concepts related to the modeling of structure Subpart II: Concepts related to the modeling of behavior Subpart III: Supplementary concepts 即结构模型概念、行为模型概念和其它概念。

UML结构图和行为图分类

原图见Superstructure: Figure A.5 - The taxonomy of structure and behavior diagram