Investigando a refatoração automática de software baseada em algoritmos de otimização multiobjetivos - Silva Júnior, Leonardo Bezerra (2014)
Refactoring is a process that aims to change the code without changing the visible behavior and is used to correct structural problems in software, arising from unplanned maintenance or an unstructured development process. The mechanisms behind the refactoring process, however, are relatively complex and dangerous if done manually (for each refactoring is necessary to evaluate a number of pre and post-conditions to ensure that the behavior is not changed). Many current development tools facilitate the refactorings usage, but in a semiautomatic way, so that the programmer must detect the need for a specific refactoring. New techniques have emerged in an effort to approximate the software engineering to other engineerings with respect to process automation. In this context, the application of search algorithms arises as a means to provide support to software maintenance by automatically applying refactorings. This work fits in this context, Search-Based Software Refactoring, and investigates in detail the topic, including the proposition of a specific algorithm for the area, entitled MultiObjective Particle Swarm Optimization with Path Relinking (MOPSOPR). An open source framework which enables the search and automatic application of refactoring sequences has also been proposed. This framework allows exploration of the problem of automatic refactoring through various optimization algorithms. In particular, in this msc dissertation, the framework is used to enable comparative analysis of the proposed algorithm with the most used algorithm in the literature of this subject, the Non-Dominated Sorting Genetic Algorithm-II (NSGA-II). Several experiments were conducted, which included real-world softwares. Despite showing some positive results, the overall assessment does not indicate a unanimous superiority of the proposed algorithm compared to the NSGA-II in several experiments. However, the study revealed interesting research frontiers to be explored in future work.