Class movement and re-location: An empirical study of Java inheritance evolution

Inheritance is a fundamental feature of the Object-Oriented (OO) paradigm. It is used to promote extensibility and reuse in OO systems. Understanding how systems evolve, and specifically, trends in the movement and re-location of classes in OO hierarchies can help us understand and predict future maintenance effort. In this paper, we explore how and where new classes were added as well as where existing classes were deleted or moved across inheritance hierarchies from multiple versions of four Java systems. We observed first, that in one of the studied systems the same set of classes was continuously moved across the inheritance hierarchy. Second, in the same system, the most frequent changes were restricted to just one sub-part of the overall system. Third, that a maximum of three levels may be a threshold when using inheritance in a system; beyond this level very little activity was observed, supporting earlier theories that, beyond three levels, complexity becomes overwhelming. We also found evidence of 'collapsing' hierarchies to bring classes up to shallower levels. Finally, we found that larger classes and highly coupled classes were more frequently moved than smaller and less coupled classes. Statistical evidence supported the view that larger classes and highly coupled classes were less cohesive than smaller classes and lowly coupled classes and were thus more suitable candidates for being moved (within an hierarchy).

[1]  Qiang Tu,et al.  Growth, evolution, and structural change in open source software , 2001, IWPSE '01.

[2]  Victor R. Basili,et al.  A Validation of Object-Oriented Design Metrics as Quality Indicators , 1996, IEEE Trans. Software Eng..

[3]  Meir M. Lehman Programs, Cities, Students— Limits to Growth? , 1978 .

[4]  Annabelle McIver,et al.  Programming Methodology , 1974, Lecture Notes in Computer Science.

[5]  Michael Philippsen,et al.  A controlled experiment on inheritance depth as a cost factor for code maintenance , 2003, J. Syst. Softw..

[6]  George Loizou,et al.  Quality of manual data collection in Java software: an empirical investigation , 2007, Empirical Software Engineering.

[7]  Rachel Harrison,et al.  Experimental assessment of the effect of inheritance on the maintainability of object-oriented systems , 2000, J. Syst. Softw..

[8]  John W. Daly,et al.  Evaluating inheritance depth on the maintainability of object-oriented software , 2004, Empirical Software Engineering.

[9]  John W. Daly,et al.  Multi-method research: An empirical investigation of object-oriented technology , 1999, J. Syst. Softw..

[10]  Stéphane Ducasse,et al.  Characterizing the evolution of class hierarchies , 2005, Ninth European Conference on Software Maintenance and Reengineering.

[11]  Lionel C. Briand,et al.  Predicting fault-prone components in a java legacy system , 2006, ISESE '06.

[12]  Chris F. Kemerer,et al.  A Metrics Suite for Object Oriented Design , 2015, IEEE Trans. Software Eng..

[13]  George Loizou,et al.  The role of constructors in the context of refactoring object-oriented systems , 2003, Seventh European Conference onSoftware Maintenance and Reengineering, 2003. Proceedings..

[14]  David P. Darcy,et al.  Managerial Use of Metrics for Object-Oriented Software: An Exploratory Analysis , 1998, IEEE Trans. Software Eng..

[15]  Dewayne E. Perry,et al.  Metrics and laws of software evolution-the nineties view , 1997, Proceedings Fourth International Software Metrics Symposium.

[16]  Juan Fernández-Ramil,et al.  Studying the evolution of open source systems at different levels of granularity: two case studies , 2004, Proceedings. 7th International Workshop on Principles of Software Evolution, 2004..

[17]  Steve Counsell,et al.  An Empirical Study of Java System Evolution at the Method Level , 2009, 2009 Seventh ACIS International Conference on Software Engineering Research, Management and Applications.

[18]  James M. Bieman,et al.  Reuse through inheritance: a quantitative study of C++ software , 1995, SSR '95.

[19]  Mark Lorenz Object-Oriented Software Metrics , 1994 .

[20]  Daniel M. Germán,et al.  On the prediction of the evolution of libre software projects , 2007, 2007 IEEE International Conference on Software Maintenance.

[21]  Victor R. Basili,et al.  Viewing maintenance as reuse-oriented software development , 1990, IEEE Software.

[22]  Steve Counsell,et al.  Extracting refactoring trends from open-source software and a possible solution to the 'related refactoring' conundrum , 2006, SAC '06.

[23]  Michelle Cartwright,et al.  An Empirical Investigation of an Object-Oriented Software System , 2000, IEEE Trans. Software Eng..

[24]  Steve Counsell,et al.  Power law distributions in class relationships , 2003, Proceedings Third IEEE International Workshop on Source Code Analysis and Manipulation.

[25]  Lionel C. Briand,et al.  Data Mining Techniques for Building Fault-proneness Models in Telecom Java Software , 2007, The 18th IEEE International Symposium on Software Reliability (ISSRE '07).

[26]  Sallie M. Henry,et al.  Object-oriented metrics that predict maintainability , 1993, J. Syst. Softw..

[27]  Chris F. Kemerer,et al.  An Empirical Approach to Studying Software Evolution , 1999, IEEE Trans. Software Eng..

[28]  Steve Counsell,et al.  An Empirical Study of Evolution of Inheritance in Java OSS , 2008, 19th Australian Conference on Software Engineering (aswec 2008).

[29]  Maurizio Morisio,et al.  Structural evolution of an open source system: a case study , 2004, Proceedings. 12th IEEE International Workshop on Program Comprehension, 2004..