DocumentCode
3284190
Title
Client based Object-Oriented Cohesion Metrics
Author
Mäkelä, Sami ; Leppänen, Ville
Author_Institution
Univ. of Turku, Turku
Volume
2
fYear
2007
fDate
24-27 July 2007
Firstpage
743
Lastpage
748
Abstract
For code quality control, there exists tens of object- oriented (OO) metrics on class cohesion and coupling. This abundant variety indicates that designing feasible metrics to differentiate good object-oriented programs from bad ones is not an easy task. Even worse, in practice OO cohesion metrics have a minor role in code reviews. In this paper we argue the proposed cohesion metrics, based on internal usage of class members, yield misleading (bad) values for several reasons. We propose a totally different kind of cohesion metric based on external class usage. Cohesion metrics typically define a bipartite usage graph between methods of a class and its variables. Providing different interpretations for methods, variables, usage relation, and calculation method have served as sources of variation. Classical interpretation is to measure internal usage of instance variables by the instance methods of a class to evaluate relatedness of the class properties. We argue that the relatedness also depends on the usage context, e.g. an application. Another problem is that objects often consist of property sets that are only slightly related internally, since an inheriting class often defines properties that are only slightly related to the inherited ones. Yet, the clients of such objects often make connections between the property sets by simultaneously advancing internally seemingly unrelated property sets. We propose forming cohesion graphs between the clients of a class and its member variables. Our approach complements the internal cohesion view with external views based on the external usage of class properties. We provide results for three popular open-source projects indicating our external cohesion measure to give much more meaningful results.
Keywords
data flow graphs; object-oriented programming; public domain software; software libraries; software metrics; software quality; bipartite usage graph; class cohesion; class coupling; client based OO cohesion metrics; code quality control; object-oriented metrics; object-oriented programs; open-source projects; Application software; Banking; Biomedical measurements; Bipartite graph; Computer applications; Gettering; Information technology; Open source software; Quality control;
fLanguage
English
Publisher
ieee
Conference_Titel
Computer Software and Applications Conference, 2007. COMPSAC 2007. 31st Annual International
Conference_Location
Beijing
ISSN
0730-3157
Print_ISBN
0-7695-2870-8
Type
conf
DOI
10.1109/COMPSAC.2007.90
Filename
4291203
Link To Document