FOOD: An Intermediate Model for Automated Refactoring

  • Authors:
  • Nicolas Juillerat;Béat Hirsbrunner

  • Affiliations:
  • University of Fribourg, Department of Computer Sciences, 1700 Fribourg, Switzerland;University of Fribourg, Department of Computer Sciences, 1700 Fribourg, Switzerland

  • Venue:
  • Proceedings of the 2006 conference on New Trends in Software Methodologies, Tools and Techniques: Proceedings of the fifth SoMeT_06
  • Year:
  • 2006

Quantified Score

Hi-index 0.00

Visualization

Abstract

As big software projects grow, there is an increasing need of cleaning up or restructuring the existing code. This problem can be addressed by using refactorings, which are small semantics-preserving code transformations. Many refactorings have been automated in existing development environments to help the developer in this process. Most implementations are currently based on the abstract syntax tree. Unfortunately, this model, which was first designed for the compilation process, does not provide all the abstractions that are required for complex refactorings such as extracting a method. In this paper, the FOOD model is introduced and described. Based entirely on graphs, this model is targeted to the implementation of complex code transformations by providing the necessary abstractions. The “extract method” refactoring is applied on the FOOD model as a concrete example. Then a comparison with existing models such as abstract syntax trees is made.