当前位置: X-MOL 学术Int. J. Softw. Eng. Knowl. Eng. › 论文详情
Our official English website, www.x-mol.net, welcomes your feedback! (Note: you will need to create a separate account there.)
ABMMRS Eradicator: Improving Accuracy in Recommending Move Methods for Web-based MVC Projects and Libraries Using Method’s External Dependencies
International Journal of Software Engineering and Knowledge Engineering ( IF 0.9 ) Pub Date : 2020-10-21 , DOI: 10.1142/s0218194020500357
Atish Kumar Dipongkor 1 , Iftekhar Ahmed 2 , Rayhanul Islam 2 , Nadia Nahar 2 , Abdus Satter 2 , Md. Saeed Siddik 2
Affiliation  

Move Method Refactoring (MMR) is used to place highly coupled methods in appropriate classes for making source code more cohesive. Like other refactoring techniques, it is mandatory that applying MMR will preserve applications’ behaviors. However, traditional MMR techniques failed to meet this essential precondition for Action methods in web-based application and API methods in libraries projects. The reason is that applying MMR on these methods changes the behaviors of the projects by raising Application-breaking issues, for instance, failure of browser requests and compilation errors in client projects. To resolve this problem, developers are suggested to manually check Action and API methods while applying MMR. However, manually inspecting thousands of lines of code for these issues is a time-consuming and hectic task. In this paper, an advanced MMR technique is proposed which automatically identifies Application-breaking MMR suggestions. This technique first takes the initial move method suggestions from the existing prominent MMR techniques e.g. JDeodorant. For each of the suggestions, it parses the source code and construct Abstract Syntax Tree to examine two types of usage. One is whether a suggestion has not been used in any unit test and Regular Class, and another is whether the suggestion has been used in unit test classes only. If any MMR suggestion is found having one of these two types of usage or both, the respective suggestion is marked as Application-breaking. In order to evaluate the proposed technique, several experiments have been conducted on open source projects. The experimental results show that the proposed technique achieved 96.4% Precision, 90% Recall and 93.1% F-score in detecting Application-breaking MMR suggestions, because of considering external dependencies of the MMR suggestions.

中文翻译:

ABMMRS Eradicator:使用方法的外部依赖项提高为基于 Web 的 MVC 项目和库推荐移动方法的准确性

移动方法重构 (MMR) 用于将高度耦合的方法放置在适当的类中,以使源代码更具凝聚力。与其他重构技术一样,应用 MMR 必须保留应用程序的行为。然而,传统的 MMR 技术未能满足基于 Web 的应用程序中的 Action 方法和图书馆项目中的 API 方法的这一基本前提。原因是在这些方法上应用 MMR 通过引发应用程序中断问题来改变项目的行为,例如,浏览器请求失败和客户端项目中的编译错误。为解决此问题,建议开发者在应用 MMR 时手动检查 Action 和 API 方法。但是,针对这些问题手动检查数千行代码是一项耗时且繁重的任务。在本文中,提出了一种先进的 MMR 技术,可自动识别破坏应用程序的 MMR 建议。该技术首先从现有的著名 MMR 技术(例如 JDeodorant)中获取初始移动方法建议。对于每个建议,它都会解析源代码并构建抽象语法树来检查两种类型的用法。一个是建议是否没有在任何单元测试和常规类中使用,另一个是建议是否仅在单元测试类中使用。如果发现任何 MMR 建议具有这两种使用类型之一或两者兼有,则相应的建议将被标记为应用程序中断。为了评估所提出的技术,已经在开源项目上进行了一些实验。实验结果表明,所提出的技术达到了 96.4% 的精度,
更新日期:2020-10-21
down
wechat
bug