{"title":"Functionality Based Code Smell Detection and Severity Classification","authors":"Omkarendra Tiwari, R. Joshi","doi":"10.1145/3385032.3385048","DOIUrl":null,"url":null,"abstract":"The Long Method code smell is a symptom of design defects caused by implementing multiple tasks within a single method. It limits reusability, evolvability and maintainability of a method. In this paper, we present a functionality based approach for detecting long methods. Functionalities are identified through a novel block based dependency analysis technique called Segmentation. It clusters sets of statements into extract method opportunities (or tasks). The approach uses interdependencies among various extract method opportunities identified within the method as a means to measure severity of the long method smell. The approach is validated over a Java based open source code. A comparison with expert's assessment shows that the approach is promising in detecting severe methods irrespective of their sizes.","PeriodicalId":382901,"journal":{"name":"Proceedings of the 13th Innovations in Software Engineering Conference on Formerly known as India Software Engineering Conference","volume":"6 1","pages":"0"},"PeriodicalIF":0.0000,"publicationDate":"2020-02-27","publicationTypes":"Journal Article","fieldsOfStudy":null,"isOpenAccess":false,"openAccessPdf":"","citationCount":"3","resultStr":null,"platform":"Semanticscholar","paperid":null,"PeriodicalName":"Proceedings of the 13th Innovations in Software Engineering Conference on Formerly known as India Software Engineering Conference","FirstCategoryId":"1085","ListUrlMain":"https://doi.org/10.1145/3385032.3385048","RegionNum":0,"RegionCategory":null,"ArticlePicture":[],"TitleCN":null,"AbstractTextCN":null,"PMCID":null,"EPubDate":"","PubModel":"","JCR":"","JCRName":"","Score":null,"Total":0}
引用次数: 3
Abstract
The Long Method code smell is a symptom of design defects caused by implementing multiple tasks within a single method. It limits reusability, evolvability and maintainability of a method. In this paper, we present a functionality based approach for detecting long methods. Functionalities are identified through a novel block based dependency analysis technique called Segmentation. It clusters sets of statements into extract method opportunities (or tasks). The approach uses interdependencies among various extract method opportunities identified within the method as a means to measure severity of the long method smell. The approach is validated over a Java based open source code. A comparison with expert's assessment shows that the approach is promising in detecting severe methods irrespective of their sizes.