Font Size: a A A

Exploring The Impact Of Code Smells On Android Mobile Projects’ Bug-Proneness

Posted on:2024-05-06Degree:MasterType:Thesis
Country:ChinaCandidate:S Y ZhangFull Text:PDF
GTID:2568307178473954Subject:Software engineering
Abstract/Summary:PDF Full Text Request
In recent years,mobile applications have become increasingly common in our daily lives,and their use cases have become increasingly diverse.Thousands of mobile applications are developed and released every month.Compared to traditional desktop software,mobile applications are typically smaller in size but contain more features,requiring faster development and delivery.However,as the complexity of Android mobile applications increases,defects and errors have become more common,which can lead to issues such as unstable applications,functional failures,and security vulnerabilities,affecting user experience.Code smells refer to poor quality features present in code that can make it difficult to understand,extend,and maintain,ultimately affecting the quality and reliability of the program.Code smells typically reflect deeper issues in the program,such as poor design and implementation.Numerous studies have shown that code smells have a negative impact on software project development and maintenance,including increasing the number and severity of defects,reducing code maintainability,and increasing maintenance costs.Due to the need for rapid delivery of mobile applications and the lack of experience of some developers,the occurrence of code smells has become difficult to avoid.However,existing research has primarily focused on the impact of code smells on desktop software,with little analysis of their impact on mobile applications.To address this gap,this paper conducted an empirical study to explore whether and to what extent code smells affect the tendency for Android mobile applications to generate bugs.This paper studied 50 Android mobile application projects from Git Hub to investigate the distribution of code smells in Android mobile applications and the extent to which code smells affect their tendency to generate bugs.The results showed that most files in mobile application projects had code smells,and the more types of code smells a file contained,the higher its tendency to generate bugs.Based on this,the paper further analyzed the impact of each type of code smell on Android mobile applications and explored the correlation between different types of code smells to help developers improve refactoring efficiency.The results showed that in Android mobile application projects,Unutilized Abstraction,Long Statement,Magic Number,Deficient Encapsulation,and CyclicDependent Modularization were the five most influential types of code smells.In addition,among the 27 types of code smells,there were four strong association rules with a confidence level greater than 0.6.The strongest association was {Complex Method} =>{Long Statement},with a confidence level of 0.8.This indicates that when the code smell Complex Method appears in a file,there is an 80% chance that the Long Statement code smell will also appear.Therefore,when encountering the Complex Method code smell,developers should also consider the Long Statement code smell to formulate a more reasonable refactoring plan.
Keywords/Search Tags:Android Mobile Projects, Code Smells, Commit Records, Empirical Study
PDF Full Text Request
Related items