The Case for Non-Cohesive Packages - Inria - Institut national de recherche en sciences et technologies du numérique Access content directly
Conference Papers Year : 2017

The Case for Non-Cohesive Packages


While the lack of cohesiveness of modules in procedural languages is a good way to identify modules with potential quality problems, we doubt that it is an adequate measure for packages in object-oriented systems. Indeed, mapping procedural metrics to object-oriented systems should take into account the building principles of object-oriented programming: inheritance and late binding. Inheritance offers the possibility to create packages by just extending classes with the necessary increment of behavior. Late binding coupled to the " Hollywood Principle " are a key to build frameworks and let the users branch their extensions in the framework. Therefore, a package extending a framework does not have to be cohesive, since it inherits the framework logic, which is encapsulated in framework packages. In such a case, the correct modularization of an extender application may imply low cohesion for some of the packages. In this paper we confirm these conjectures on various real systems (JHotdraw, Eclipse, JEdit, JFace) using or extending OO frameworks. We carry out a dependency analysis of packages to measure their relation with their framework. The results show that framework dependencies form a considerable portion of the overall package dependencies. This means that non-cohesive packages should not be considered systematically as packages of low quality.
Fichier principal
Vignette du fichier
paper-anq.pdf (350.32 Ko) Télécharger le fichier
Origin : Files produced by the author(s)

Dates and versions

hal-01585703 , version 1 (24-09-2017)



Nicolas Anquetil, Muhammad Usman Bhatti, Stéphane Ducasse, André Hora, Jannik Laval. The Case for Non-Cohesive Packages. SQAMIA 2017 - 6th workshop on Software Quality Analysis, Monitoring, Improvement, and Applications, Sep 2017, Belgrade, Serbia. ⟨10.1145/0000000.0000000⟩. ⟨hal-01585703⟩
278 View
88 Download



Gmail Facebook Twitter LinkedIn More