Parameter-based refactoring and the relationship with fan-in/fan-out coupling
By: Alessandro Murgia, Roberto Tonelli, Giulio Concas, Michele Marchesi, Steve Counsell
Abstract
In this paper, we analyze the effect of particular refactorings on class coupling for different aggregate releases of four object-oriented Open Source (OS) Java software systems: Azureus, Jtopen, Jedit and Tomcat, as representative of general Java OS systems. Specifically, the "add parameter" to a method and "remove parameter" from a method refactorings, as defined according to Fowler, may influence class coupling changing fan-in and fan-out of classes they are applied to. We investigate, both qualitatively and quantitatively, using a statistical approach, the global effect of the application of such refactorings, providing best fitting statistical distributions able to describe the changes in fan-in and fan-out couplings. Results show a net tendency of developers to apply such refactorings to classes with relatively high fan-in and fan-out and a persistence of the same statistical distribution for fan-in and fan-out before and after refactoring. Finally, we provide a detailed analysis of the best fitting parameters and of their changes when refactoring occurs, which may be useful for estimating the effect of refactoring on coupling before it is applied. Since refactoring requires time and effort, these estimates may help in determining costs and benefits.
Keywords
Refactoring, Coupling, Metric distribution, Fan-in, Fan-out
Cite as:
Alessandro Murgia, Roberto Tonelli, Giulio Concas, Michele Marchesi, Steve Counsell, “Parameter-based refactoring and the relationship with fan-in/fan-out coupling”, Journal of Object Technology, Volume 11, no. 2 (August 2012), pp. 7:1-24, doi:10.5381/jot.2012.11.2.a7.
PDF | DOI | BiBTeX | Tweet this | Post to CiteULike | Share on LinkedIn