Identification of Move Method Refactoring Opportunities

By Nikolaos Tsantalis, A. Chatzigeorgiou. IEEE Transactions on Software Engineering, 2009

372 citations recorded by the source corpus.

Placement of attributes/methods within classes in an object-oriented system is usually guided by conceptual criteria and aided by appropriate metrics. Moving state and behavior between classes can help reduce coupling and increase cohesion, but it is nontrivial to identify where such refactorings should be applied. In this paper, we propose a methodology for the identification of Move Method refactoring opportunities that constitute a way for solving many common feature envy bad smells. An algorithm that employs the notion of distance between system entities (attributes/methods) and classes extracts a list of behavior-preserving refactorings based on the examination of a set of preconditions. In practice, a software system may exhibit such problems in many different places. Therefore, our approach measures the effect of all refactoring suggestions based on a novel entity placement metric that quantifies how well entities have been placed in system classes. The proposed methodology can be regarded as a semi-automatic approach since the designer will eventually decide whether a suggested refactoring should be applied or not based on conceptual or other design quality criteria. The evaluation of the proposed approach has been performed considering qualitative, metric, conceptual, and efficiency aspects of the suggested refactorings in a number of open-source projects.

Subfields: Information Systems, Software

View Paper: https://www.semanticscholar.org/paper/88c7e496d828ced15dca824d6fcb24de8c4c6804

How researchers see this paper

The researchers whose trusted networks rank it highest, strongest advocate first. Every researcher gets a different order.

In Information Systems

  1. Earl T. Barr
  2. Gabriele Bavota
  3. Premkumar T. Devanbu
  4. Michele Tufano
  5. Denys Poshyvanyk
  6. Mark Harman
  7. Charles Sutton
  8. Miltiadis Allamanis

In Software

  1. Earl T. Barr
  2. Gabriele Bavota
  3. Premkumar T. Devanbu
  4. Denys Poshyvanyk
  5. Michele Tufano
  6. Yuriy Brun
  7. Charles Sutton
  8. Massimiliano Di Penta

Citations in the corpus