Schizophrenic Classes

Project Idea

The SOLID principles state that a class should have only one reason to be changed, it should have only one responsibility. But how can we identify classes that have multiple responsibilities (i.e., classes that are schizophrenic as they have multiple identities)? The goal of the project is to find schizophrenic classes*. To achieve that, the classes itself can be analyzed using metrics as cohesion etc. It is also possible to analyze the usage of classes, e.g., to extract groups of methods often invoked in together. Tracking the evolution of a class in a version control system could identify such classes as they are split up into multiple classes. A possible application of the implemented approach could be a proposal on how to split up a schizophrenic class into single identity classes.

*Term coined by Boris Spasojević in his PhD defense.

Contact

Manuel Leuenberger

Last changed by scg on 9 November 2017