软件设计模式违反的识别与评估
Identification and Assessment of Software Design Pattern Violations
摘要:
为了在快速开发环境中保存、扩展和重用软件项目,设计模式实现的验证以识别模式违反已经成为重新工程过程的一部分。如果设计模式实现不符合它们的定义,则会被视为违规。软件老化和开发人员缺乏经验是设计模式违反的根源。根据一些预定义的特征来检查设计模式实现的正确性以检测和纠正违规,从而降低成本是很重要的。目前,已经开发了几种工具来检测设计模式实例,但在创建一个自动化工具来识别和验证设计模式违规方面所做的工作很少。在本文中,我们提出了一个设计模式违规识别和评估(DPVIA)工具,它有能力识别软件设计模式违规,并报告模式实例实现的一致性得分对一组预定义的特征,任何设计模式定义,无论是Gang of Four(GoF)设计模式由Gamma等人[1];或自定义模式由软件开发人员。此外,我们已经验证了所提出的工具的有效性,使用两个评估实验和结果进行手动检查。最后,为了评估所提出的工具的功能,它进行了评估与数据集包含5,679,964行代码中的28,669在15个开源项目,与大小的开源项目,广泛和系统地采用设计模式,以确定设计模式的违规行为,并建议重构解决方案,从而保持软件进化的成本。软件架构师可以使用这些结果在使用设计模式的同时开发最佳实践。
英文摘要:
The validation of design pattern implementations to identify pattern violations has gained more relevance as part of re-engineering processes in order to preserve, extend, reuse software projects in rapid development environments. If design pattern implementations do not conform to their definitions, they are considered a violation. Software aging and the lack of experience of developers are the origins of design pattern violations. It is important to check the correctness of the design pattern implementations against some predefined characteristics to detect and to correct violations, thus, to reduce costs. Currently, several tools have been developed to detect design pattern instances, but there has been little work done in creating an automated tool to identify and validate design pattern violations. In this paper we propose a Design Pattern Violations Identification and Assessment (DPVIA) tool, which has the ability to identify software design pattern violations and report the conformance score of pattern instance implementations towards a set of predefined characteristics for any design pattern definition whether Gang of Four (GoF) design patterns by Gamma et al[1]; or custom pattern by software developer. Moreover, we have verified the validity of the proposed tool using two evaluation experiments and the results were manually checked. Finally, in order to assess the functionality of the proposed tool, it is evaluated with a data-set containing 5,679,964 Lines of Code among 28,669 in 15 open-source projects, with a large and small size of open-source projects that extensively and systematically employing design patterns, to determine design pattern violations and suggest refactoring solutions, thus keeping costs of software evolution. The results can be used by software architects to develop best practices while using design patterns.
机构、总结、中文摘要均由AI分析而来,可能存在错误,请以论文正文为准。