作者投稿和查稿 主编审稿 专家审稿 编委审稿 远程编辑

计算机工程 ›› 2006, Vol. 32 ›› Issue (13): 69-70,1. doi: 10.3969/j.issn.1000-3428.2006.13.025

• 软件技术与数据库 • 上一篇    下一篇

用Z形式化描述的软件设计模式

曾红卫;滕中梅   

  1. 上海大学计算机学院,上海 200072
  • 收稿日期:1900-01-01 修回日期:1900-01-01 出版日期:2006-07-05 发布日期:2006-07-05

Formalizing Software Design Pattern in Z

ZENG Hongwei;TENG Zhongmei   

  1. School of Computer, Shanghai University, Shanghai 200072
  • Received:1900-01-01 Revised:1900-01-01 Online:2006-07-05 Published:2006-07-05

摘要: 设计模式和形式化是软件工程领域研究的两个重要方面。该文的目的是对设计模式的形式化进行探讨,其中心是设计模式“结构”的形式化。文章以抽象类、抽象函数为基本对象,分析了设计模式中类和函数间存在的各种基本关系和关系性质,提出了“层次”概念。在此基础上,以设计模式“修饰”为例说明了用Z语言形式化设计模式的方法。

关键词: 设计模式, 形式化, 层次, 修饰

Abstract: Design pattern and formalizing are two very important aspects of software engineering. This paper discusses formalizing design pattern. It focuses on “Structure” section of each pattern. Based on classes and functions, first, the paper analyses basis relations among classes and relations, and properties of relation. It brings forward a notation of hierarchy construct. As an example, it transforms from structure section of pattern “decorator” into formal description in Z.

Key words: Design pattern, Formalizing, Hierarchy, Decorator

中图分类号: