《计算机应用》唯一官方网站 ›› 2024, Vol. 44 ›› Issue (3): 883-889.DOI: 10.11772/j.issn.1001-9081.2022111702

• 计算机软件技术 • 上一篇    下一篇

基于UMCS树的UML类图的混合相似性度量

袁中臣1(), 马宗民2   

  1. 1.沈阳工业大学 化工过程自动化学院,辽宁 辽阳 111004
    2.南京航空航天大学 计算机科学与技术学院,南京 211106
  • 收稿日期:2022-11-16 修回日期:2023-11-15 接受日期:2023-12-05 发布日期:2024-01-05 出版日期:2024-03-10
  • 通讯作者: 袁中臣
  • 作者简介:马宗民(1965—),男,山东金乡人,教授,博士生导师,博士,CCF高级会员,主要研究方向:知识图谱。
  • 基金资助:
    国家自然科学基金资助项目(62176121);辽宁省教育厅基本研究项目(LJKZ0165)

UMCS tree based hybrid similarity measure of UML class diagram

Zhongchen YUAN1(), Zongmin MA2   

  1. 1.School of Chemical Process Automation,Shenyang University of Technology,Liaoyang Shenyang 111004,China
    2.School of Computer Science and Technology,Nanjing University of Aeronautics and Astronautics,Nanjing Jiangsu 211106,China
  • Received:2022-11-16 Revised:2023-11-15 Accepted:2023-12-05 Online:2024-01-05 Published:2024-03-10
  • Contact: Zhongchen YUAN
  • About author:MA Zongmin, born in 1965, Ph. D., professor. His research interests include knowledge graph.
  • Supported by:
    National Natural Science Foundation of China(62176121);Basic Research Project of Education Department of Liaoning Province(LJKZ0165)

摘要:

软件重用是基于给定条件从存储库中检索以前开发的软件产品,检索基于相似性度量。UML(Unified Modeling Language)类图被广泛应用于软件设计,UML类图重用作为软件设计重用的核心而备受关注。因此,对UML类图的相似性开展研究。类图包含语义和结构信息。目前,UML类图的相似性研究主要集中在语义,也有个别讨论结构相似性,但没有考虑将语义和结构相结合。因此,提出一种结合语义和结构的混合相似性度量。鉴于UML类图的非形式化特征,将UML类图转换成图模型,搜索最大公共子图列表,构建了最大公共子图树,提出一个基于最大公共子图序列的混合相似性度量方法。针对概念公共子图和结构公共子图分别定义了语义匹配和结构匹配,并开展了相似性对比和基于相似性的分类质量比较实验,实验结果验证了所提出方法的优势。

关键词: UML类图, 模型转换, 混合相似性, 最大公共子图树, 语义匹配, 结构匹配

Abstract:

Software reuse is to retrieve previously developed software artifacts from a repository according to given conditions. The retrieval is based on similarity measure. UML (Unified Modeling Language) class diagram is widely applied to software design, and its reuse as a core of software design reuse has attracted much attention. Therefore, the research on the similarity of UML class diagrams was carried out. UML class diagram contains semantic and structural contents. At present, the similarity research of UML class diagrams mainly focuses on semantics, and there are also some discussions on structural similarity, but the combination of semantics and structure has not been considered. Therefore, a hybrid similarity measure combining semantics and structure was proposed. Due to the non-formal nature of UML class diagram, the UML class diagram was transformed into a graph model for similarity measure, the Maximum Common Subgraph List (MCSL) was searched, a Maximum Common Subgraph (MCS) tree was created based on MCSL, and a hybrid similarity measure method was proposed based on MCS sequence. The semantic matching and structural matching were defined corresponding to concept and structure common subgraphs, respectively. The similarity comparison and similarity based classification quality comparison experiments were carried out, and the experimental results validate the advantages of the proposed method.

Key words: UML (Unified Modeling Language) class diagram, model transformation, hybrid similarity, maximum common subgraph tree, semantic matching, structural matching

中图分类号: