Skip to main content

Implementation of Analytical Hierarchy Process in Detecting Structural Code Clones

  • Conference paper
  • First Online:

Part of the book series: Lecture Notes in Computer Science ((LNTCS,volume 10408))

Abstract

The nature and the size of data plays an important rule at the identification process of similar objects (clones). The type of utilized similarity measures is also an important factor. The nature of data and selecting the right identification algorithm appropriate to type of data should be examined thoroughly when a clone identification technique is applied. This study suggests a new methodology in software systems for minimization/prevention of code cloning. Its main contribution is to propose an Analytical Hierarchy Process based methodology at detection of code clones in object-oriented software systems, in which the software is represented by means of software metrics data at class level. The suggested clone detection model is able to select the most suitable code clone candidates by considering different correlation and distance metrics to identify code clones. To facilitate the testing and the usability of the suggested clone detection model, the system is used for detection of structural code clone. The methodology is validated by comparison with results obtained by human judges as well as by comparison with a plain structural code clone identification approach. The evaluation of the methodology is carried out in terms of accuracy and indicates promising results.

This is a preview of subscription content, log in via an institution.

Buying options

Chapter
USD   29.95
Price excludes VAT (USA)
  • Available as PDF
  • Read on any device
  • Instant download
  • Own it forever
eBook
USD   39.99
Price excludes VAT (USA)
  • Available as EPUB and PDF
  • Read on any device
  • Instant download
  • Own it forever
Softcover Book
USD   54.99
Price excludes VAT (USA)
  • Compact, lightweight edition
  • Dispatched in 3 to 5 business days
  • Free shipping worldwide - see info

Tax calculation will be finalised at checkout

Purchases are for personal use only

Learn about institutional subscriptions

References

  1. Kapdan, M., Aktas, M., Yigit, M.: On the structural code clone detection problem: a survey and software metric based approach. In: Murgante, B., Misra, S., Rocha, Ana Maria A.C., Torre, C., Rocha, J.G., Falcão, M.I., Taniar, D., Apduhan, Bernady O., Gervasi, O. (eds.) ICCSA 2014. LNCS, vol. 8583, pp. 492–507. Springer, Cham (2014). doi:10.1007/978-3-319-09156-3_35

    Google Scholar 

  2. Aktas, M., Kapdan, M.: Structural code clone detection methodology using software metrics. Int. J. Softw. Eng. Knowl. Eng. 26(2), 307–332 (2016)

    Article  Google Scholar 

  3. Huang, A.: Similarity measures for text document clustering, In: NZCSRSC 2008, Christchurch, New Zealand, April 2008

    Google Scholar 

  4. Xue, Y.: Reengineering legacy software products into software product line, Ph.D. thesis, CS Department, National University of Singapure, January 2013

    Google Scholar 

  5. Stherl, A., Ghosh, J., Mooney, R.: Impact of similarity measures on web page clustering, AAAI Technical report WS-00-01, 2000 AAAI (www.aaai.org)

  6. Saaty, T.L.: The Analytic Hierarchy Process. McGraw-Hill, New York (1980)

    MATH  Google Scholar 

  7. Gil, J.Y., Maman, I.: Micro patterns in Java code. In: SIGPLAN Notices, 2005, New York (2005)

    Google Scholar 

  8. Shi, N., Olsson, R.A.: Reverse engineering of design patterns from java source code. In: Proceedings of the 21st IEEE/ACM International Conference on Automated Software Engineering, ASE 2006, 18–22 September 2006, Tokyo (2006)

    Google Scholar 

  9. Basit, H., Ali, U., Jarzabek, S.: Viewing simple clones from structural clones’ perspective. In: Proceedings of the 5th International Workshop on Software Clones, 23 May 2011, Honolulu (2011)

    Google Scholar 

  10. De Lucia, A., Francese, R., Scanniello, G., Tortora, G.: Reengineering web applications based on cloned pattern analysis. In: Proceedings of the 12th IEEE International Workshop on Program Comprehension, 24–26 June 2004, Bari (2004)

    Google Scholar 

  11. Marcus, A., Maletic, J.I.: Identification of high-level concept clones in source code. In: Proceedings 16th Annual International Conference on Automated Software Engineering, 2001, Chicago (2001)

    Google Scholar 

  12. Kim, S., Pan, K., Whitehead, E.J.: When functions change their names: automatic detection of origin relationships. In: Proceedings of the 12th Working Conference on Reverse Engineering, 7–11 November 2005, Pittsburgh (2005)

    Google Scholar 

  13. Dynamic and Distributed Information Systems Group, U.o.Z., (2014). “SimPack”. https://files.ifi.uzh.ch/ddis/oldweb/ddis/research/simpack/index.html. 15 August 2014

  14. Wellington, B.: “DNS Java” (1999). http://www.dnsjava.org/. 15 August 2014

  15. GitHub Software Repository address: mkapdan: Mustafa Kapdan Repositories (2014). https://github.com/mkapdan?tab=repositories. 15 August 2014

Download references

Author information

Authors and Affiliations

Authors

Corresponding author

Correspondence to Mehmet S. Aktas .

Editor information

Editors and Affiliations

Rights and permissions

Reprints and permissions

Copyright information

© 2017 Springer International Publishing AG

About this paper

Cite this paper

Aktas, M.S., Kapdan, M. (2017). Implementation of Analytical Hierarchy Process in Detecting Structural Code Clones. In: Gervasi, O., et al. Computational Science and Its Applications – ICCSA 2017. ICCSA 2017. Lecture Notes in Computer Science(), vol 10408. Springer, Cham. https://doi.org/10.1007/978-3-319-62404-4_48

Download citation

  • DOI: https://doi.org/10.1007/978-3-319-62404-4_48

  • Published:

  • Publisher Name: Springer, Cham

  • Print ISBN: 978-3-319-62403-7

  • Online ISBN: 978-3-319-62404-4

  • eBook Packages: Computer ScienceComputer Science (R0)

Publish with us

Policies and ethics