###
DOI:
Journal of Software:2009.20(6):1487-1498

UML类图层次化自动布图算法
王晓博,王欢,刘超
(北京航空航天大学 软件工程研究所,北京 100191)
Automatic Hierarchical Layout Algorithm for UML Class Diagram
WANG Xiao-Bo,WANG Huan,LIU Chao
()
Abstract
Chart / table
Reference
Similar Articles
Article :Browse 4449   Download 5815
Received:April 03, 2008    Revised:July 02, 2008
> 中文摘要: UML类图能够有效地帮助软件工程师理解大规模的软件系统,而优化图元的空间布局可以增强类图的可读性和可理解性.由于类图中继承关系具有明显的层次特性,因此类图自动布局大多采用层次化的布图算法.此外,类图布局需要考虑相关的领域知识以及绘制准则,因而通用嵌套有向图层次化布局算法不能直接用于类图的绘制,它们必须加以扩展.但是,已有的类图层次化方法并没有考虑类图中图元的嵌套关系,这将导致自动布局方法不能处理类图中包与类、接口之间的包含关系.在考虑图绘制美学、UML类图绘制以及软件可视化等相关知识的基础上,选取了一组布
Abstract:UML class diagrams are helpful for understanding complicated object-oriented software systems. The reasonable placement of diagram elements can make class diagrams more readable and understandable. As inheritance is regarded as a hierarchical relation, the hierarchical layout method is usually adopted to draw UML class diagrams. Because the domain specific knowledge and drawing criteria related to class diagrams must be considered in the layout of diagrams, general hierarchical layout algorithms for nested digraphs should be extended according to these criteria. But existing hierarchical layout algorithms for class diagrams cannot handle the nested relations among packages, classes, and interfaces, and existing compound layout methods for digraphs cannot be used directly to draw class diagrams. Layout criteria are selected based on the knowledge of graph drawing aesthetics, UML class diagram semantics and software visualization. In addition, the nested constraints in rank assignment, edge crossing, and coordinate assignment of hierarchical layout method were also analyzed in this paper. Then, existing hierarchical layout algorithm was extended to cope with nested graphs according to nested criteria. Experiment results show that the drawings of the reversed class diagrams are more readable and understandable with proper hierarchies, nested relations, less crossings and optimal drawing area.
文章编号:     中图分类号:    文献标志码:
基金项目:Supported by the National Natural Science Foundation of China under Grant No.90718018 (国家自然科学基金); the National High-Tech Research and Development Plan of China under Grant No.2006AA01Z176 (国家高技术研究发展计划(863)) Supported by the National Natural Science Foundation of China under Grant No.90718018 (国家自然科学基金); the National High-Tech Research and Development Plan of China under Grant No.2006AA01Z176 (国家高技术研究发展计划(863))
Foundation items:
Reference text:

王晓博,王欢,刘超.UML类图层次化自动布图算法.软件学报,2009,20(6):1487-1498

WANG Xiao-Bo,WANG Huan,LIU Chao.Automatic Hierarchical Layout Algorithm for UML Class Diagram.Journal of Software,2009,20(6):1487-1498