Abstract

Objective: Code smells indicate the design decay in software applications. The code smells existence in the software will hinder the understandability of code and possibly increases changes and fault proneness. Methods / Statistical Analysis: To remove the code smells’ from the software applications refactoring operations are applied which in turn improves the software system structure without changing its overall behaviour. Generally, in a large sized system, code smell cannot be fixed automatically. Therefore based on the maintainer’s preference, the prioritized list of refactoring sequences to fix the code smells is essential. Findings: Majority of the refactoring just rely on the structural information, which fails to preserve the construct semantics, minimization of changes and the use of development history. To overcome this, in this work, the Strength Pareto Evolutionary Algorithm (SPEA) is used to prioritize the list of refactoring operations that maximize the quality improvement, constructs semantics coherence and preserving the consistency with the previous refactoring. This work is carried out on two open source software Xerces-J and J Hot Draw. Blob, shotgun surgery, functional decomposition, data class, Swiss army knife and schizophrenic class code smells’ are considered for prioritizing refactoring operations in these open source system. SPEA is evaluated using the metrics Code smell Correction Ratio (CCR) and Refactoring Meanings (RM). Application / Improvements: SPEA is compared with other algorithms namely Non-dominated Sorting Genetic Algorithm II (NSGA II) and Chemical Reaction Optimization (CRO), to prove its efficiency in prioritizing code smell correction tasks. Keywords: Code Smells, Maintenance, Prioritizing, Refactoring, Search Based Software Engineering, Strength Pareto Evolutionary Algorithm (SPEA)

Highlights

  • Software plays a vital role in all areas of human effort to produce progression

  • Strength Pareto Evolutionary Algorithm is used in suggesting automatic refactoring solutions to fix the detected code-smells’ with concern to the software maintainer’s preferences

  • The available refactoring operations are collected for the detected code smells

Read more

Summary

Introduction

Software plays a vital role in all areas of human effort to produce progression. A software system consists of programs, configuration files, project files, and system documentation and user documentation files[1]. The software systems design exhibit several problems during the initial construction or during software systems aging, where the system quality degenerates over time Some researchers view these issues in software design either as noncompliance with the system design principles or violations of software design heuristics. Code smells indicate poor software design and different system implementation choices that hinder code comprehension which possibly increases the changeability and liability of faults in the software[3]. Such symptoms may originate from activities performed by developers during the submission of project. Based on the maintainer’s preference, the prioritized list of refactoring sequence is needed to fix the code smells for the large systems

Methods
Results
Conclusion
Full Text
Published version (Free)

Talk to us

Join us for a 30 min session where you can share your feedback and ask us any queries you have

Schedule a call