skip to main content
research-article

Restructuring of Object-Oriented Software Through Cohesion Improvement Using Frequent Usage Patterns

Published: 05 September 2017 Publication History

Abstract

Due to wide adoption of object-oriented programming in software development, there is always a requirement to produce well-designed software systems, so that the overall software maintenance cost is reduced and reusability of the component is increased. But, due to prolonged maintenance activities, the internal structure of software system deteriorates. In this situation, restructuring is a widely used solution to improve the overall internal structure of the system without changing its external behavior. As, it is known that, one technique to perform restructuring is to use refactoring on the existing source code to alter its internal structure without modifying its external functionality. However, the refactoring solely depends on our ability to identify various code smells present in the system. Refactoring aims at improving cohesion and reducing coupling in the software system. So, in this paper, a restructuring approach based on refactoring is proposed through improvement in cohesion. This paper focuses on improving the cohesion of different classes of object-oriented software using a newly proposed similarity metric based on Frequent Usage Patterns (FUP). The proposed similarity metric measure the relatedness among member functions of the classes. The metric makes use of FUPs used by member functions. The FUP consists of unordered sequences of member variables accessed by member function in performing its task. The usage pattern includes both direct and indirect usages based on sub-function calls within a member function. Based on the values of the similarity metric, we performed hierarchical agglomerative clustering using complete linkage strategy to cluster member functions. Finally, based on the clusters obtained, the source code of the software is refactored using proposed refactoring algorithm. The applicability of our proposed approach is tested using two java projects related to different domains of real life. The result obtained encourages the applicability of proposed approach in the restructuring of a software system.patterns, refactoring, hierarchical clustering, maintainability. usage patterns, refactoring, hierarchical clustering, maintainability.

References

[1]
G. Uddin, B. Dagenais, and M. P. Robillard, "Temporal analysis of API usage concepts," in International Conf. on Software Engineering, 2012, pp. 804--814.
[2]
J. Wang, Y. Dang, H. Zhang, K. Chen, T. Xie, and D. Zhang, "Mining succinct and high-coverage API usage patterns from source code," in Working Conf. on Mining Software Repositories, 2013, pp. 319--328.
[3]
A. Michail, "Data mining library reuse patterns using generalized association rules," in International conference on Software engineering. ACM, 2000.
[4]
G. Scanniello and A. Marcus, "Clustering support for static concept location in source code," in Program Comprehension (ICPC),2011IEEE 19th International Conference on, 2011, pp. 1--10.
[5]
M. Perepletchikov, C. Ryan, and K. Frampton, "Cohesion metrics for predicting maintainability of service-oriented software," in International Conference on Quality Software, 2007, pp. 328--335.
[6]
H. Abdeen, H. Sahraoui, and O. Shata, "How we design interfaces, and how to assess it," in International Conference on Software Maintenance, 2013, pp. 80--89.
[7]
S. Endrikat, S. Hanenberg, R. Robbes, and A. Stefik, "How do API documentation and static typing affect API usability?" in International Conf. on Software Engineering. ACM, 2014, pp. 632--642.
[8]
R. P. L. Buse and W. Weimer, "Synthesizing API usage examples," in International Conf. on Software Engineering, 2012, pp. 782--792.
[9]
R. Hudli, C. Hoskins, and A. Hudli, "Software Metrics for Object-oriented Designs," IEEE Trans. Electron Devices, vol. 2, pp. 314--319, Jan. 1993.
[10]
L. Briand, C. Bunse, and J. Daly, A controlled experiment for evaluating quality guidelines on the maintainability of object-oriented designs, IEEE Transactions on Software Engineering, vol. 27 (6), 2001a, pp. 513--530.
[11]
H. S. Chae, Y. R. Kwon, and D. Bae, A cohesion measure for object-oriented classes, Software-Practice & Experience, 30(12), 2000, pp.1405--1431.
[12]
M. Fowler, K. Beck, J. Brant, W. Opdyke, and D. Roberts, Refactoring: Improving the Design of Existing Code. Addison-Wesley, 1999.
[13]
M. Saied, H. Abdeen, O. Benomar, and H. Sahraoui, Could We Infer API Usage Patterns only using the Library Source Code?, in International Conference on Program Comprehension (ICPC), IEEE, 2015.
[14]
H. A. Sahraoui, R. Godin, and T. Miceli. Can metrics help to bridge the gap between the improvement of OO design quality and its automation? InProc. International Conference on Software Maintenance, pages 154--162, October 2000.
[15]
F. Simon, F. Steinbr ?uckner, and C. Lewerentz. Metrics basedrefactoring. InProc. European Conf. Software Maintenanceand Reengineering, pages 30--38. IEEE Computer SocietyPress, 2001.
[16]
A. D. Lucia, R. Oliveto, and L. Vorraro. Using structural and semantic metrics to improve class cohesion. In Proceedings of International Conference on Software Maintenance (ICSM), pages 27--36, 2008.
[17]
L. Tahvildari and K. Kontogiannis, "A Metric-Based Approach to Enhance Design Quality through Meta-Pattern Transformations," Proc. Seventh European Conf. Software Maintenance and Reeng., pp. 183--192, Mar. 2003.
[18]
M. O'Keeffe and M. O'Cinneide, "Search-Based Software Maintenance," Proc. 10th European Conf. Software Maintenance and Reeng., pp. 249--260, Mar. 2006.
[19]
O. Seng, J. Stammel, and D. Burkhart, "Search-Based Determination of Refactorings for Improving the Class Structure of ObjectOriented Systems," Proc. Eighth Ann. Conf. Genetic and Evolutionary Computation, pp. 1909--1916, 2006.
[20]
O. Maqbool and H.A. Babri, "Hierarchical Clustering for Software Architecture Recovery," IEEE Trans. Software Eng., vol. 33, no. 11, pp. 759--780, Nov. 2007.
[21]
B.S. Mitchell and S. Mancoridis, "On the Automatic Modularization of Software Systems Using the Bunch Tool," IEEE Trans. Software Eng., vol. 32, no. 3, pp. 193-208, Mar. 2006.
[22]
M. Zhang, T. Hall, N. Baddoo, Code Bad Smells: a review of current knowledge, J. Software Maintenance Evolut.: Res. Practice 23 (3) (2011) 179--202.
[23]
Fokaefs M, Tsantalis N, Chatzigeorgiou A, Sander J (2009) Decomposing object-oriented class modules using an agglomerative clustering technique. In: Proceedings of the 25th international conference on software maintenance. Edmonton, Canada, pp 93--101.
[24]
Bavota G, De Lucia A, Oliveto R (2011) Identifying extract class refactoring opportunities using structural and semantic cohesion measures. J Syst Softw 84:397--414.
[25]
Joshi P, Joshi RK (2009) Concept analysis for class cohesion. In: Proceedings of the 13th European conference on software maintenance and reengineering. Kaiserslautern, Germany, pp 237--240.
[26]
Meananeatra P. (2012) Identifying refactoring sequences for improving software maintainability. In Proceedings of the 27th IEEE/ACM International Conference on Automated Software Engineering (ASE 2012). ACM, New York, NY, USA, 406--409.
[27]
Moha N, Gueheneuc YG, Duchien L, Le Meur AF (2010) Decor: a method for the specification and detection of code and design smells. IEEE Trans Softw Eng 36(1):20--36.
[28]
R. Baeza-Yates and B. Ribeiro-Neto, Modern Information Retrieval. Addison-Wesley, 1999.
[29]
Amarjeet, Jitender Kumar Chhabra, "Improving Modular Structure of Software System using structural and lexical dependency", Information & Software Technology (Elsevier, SCI), Vol 82, Feb 2017, p 96--120.
[30]
Amarjeet, Jitender Kumar Chhabra, "Preserving Core Components of Object-oriented Packages while Maintaining Structural Quality", Procedia Computer Science (Elsevier), Vol 46, 2015, pp. 833--840.

Cited By

View all
  • (2024)Performance Evaluation of Data Mining Techniques to Enhance the Reusability of Object-Oriented (O-O) SystemsEngineering, Technology & Applied Science Research10.48084/etasr.721314:4(15378-15383)Online publication date: 2-Aug-2024
  • (2024)Performance Evaluation of Support Vector Classifier Kernel Functions in Method-Level Refactoring Analysis2024 IEEE Students Conference on Engineering and Systems (SCES)10.1109/SCES61914.2024.10652412(1-6)Online publication date: 21-Jun-2024
  • (2022)DOOSRA—Distributed Object‐Oriented Software Restructuring Approach using DIM‐K‐means and MAD‐based ENRNN classifierIET Software10.1049/sfw2.1207617:1(23-36)Online publication date: 21-Dec-2022
  • Show More Cited By

Recommendations

Comments

Information & Contributors

Information

Published In

cover image ACM SIGSOFT Software Engineering Notes
ACM SIGSOFT Software Engineering Notes  Volume 42, Issue 3
July 2017
75 pages
ISSN:0163-5948
DOI:10.1145/3127360
Issue’s Table of Contents

Publisher

Association for Computing Machinery

New York, NY, United States

Publication History

Published: 05 September 2017
Published in SIGSOFT Volume 42, Issue 3

Check for updates

Author Tags

  1. Cohesion
  2. frequent usage patterns
  3. hierarchical clustering
  4. maintainability
  5. refactoring

Qualifiers

  • Research-article

Contributors

Other Metrics

Bibliometrics & Citations

Bibliometrics

Article Metrics

  • Downloads (Last 12 months)4
  • Downloads (Last 6 weeks)0
Reflects downloads up to 03 Mar 2025

Other Metrics

Citations

Cited By

View all
  • (2024)Performance Evaluation of Data Mining Techniques to Enhance the Reusability of Object-Oriented (O-O) SystemsEngineering, Technology & Applied Science Research10.48084/etasr.721314:4(15378-15383)Online publication date: 2-Aug-2024
  • (2024)Performance Evaluation of Support Vector Classifier Kernel Functions in Method-Level Refactoring Analysis2024 IEEE Students Conference on Engineering and Systems (SCES)10.1109/SCES61914.2024.10652412(1-6)Online publication date: 21-Jun-2024
  • (2022)DOOSRA—Distributed Object‐Oriented Software Restructuring Approach using DIM‐K‐means and MAD‐based ENRNN classifierIET Software10.1049/sfw2.1207617:1(23-36)Online publication date: 21-Dec-2022
  • (2020)Restructuring of Object-Oriented Software System Using Clustering TechniquesProceeding of International Conference on Computational Science and Applications10.1007/978-981-15-0790-8_41(419-425)Online publication date: 5-Jan-2020
  • (2018)An empirical approach for software reengineering process with relation to quality assurance mechanismADCAIJ: Advances in Distributed Computing and Artificial Intelligence Journal10.14201/ADCAIJ20187331467:3(31)Online publication date: 13-Sep-2018

View Options

Login options

View options

PDF

View or Download as a PDF file.

PDF

eReader

View online with eReader.

eReader

Figures

Tables

Media

Share

Share

Share this Publication link

Share on social media