GEMS: An Extract Method Refactoring Recommender

2017 IEEE 28th International Symposium on Software Reliability Engineering (ISSRE)(2017)

引用 21|浏览43
暂无评分
摘要
Extract Method is a widely used refactoring operation to improve method comprehension and maintenance. Much research has been done to extract codefragments within the method body to form a new method. Criteria used for identifying extractable code is usually centered around degrees of cohesiveness, coupling and length of the method. However, automatic method extraction techniques have not been highly successful, since it can be hard to concretizethe criteria. In this work, we present a novel system that learns these criteria for Extract Method refactorings from open source repositories. We extractstructural and functional features, which encode the concepts of complexity, cohesion and coupling in our learning model, and train it to extract suitablecode fragments from a given source of a method. Our tool, GEMS, recommends a ranked list of code fragments with high accuracy and greatspeed. We evaluated our approach on several open source repositories and compared it against three state-of-the-art approaches-SEMI, JExtract andJDeodorant. The results on these open-source data show the superiority of our machine-learning-based approach in terms of effectiveness. We develop GEMS asan Eclipse plugin, with the intention to support software reliability through method extraction.
更多
查看译文
关键词
extractable code,automatic method extraction techniques,open source repositories,GEMS,code fragments,open-source data,Extract Method refactoring recommender,widely used refactoring operation,method comprehension,maintenance,codefragments,SEMI,JExtract,JDeodorant,machine-learning based approach,Eclipse plugin,software reliability
AI 理解论文
溯源树
样例
生成溯源树,研究论文发展脉络
Chat Paper
正在生成论文摘要