ABSTRACT
Extract method refactoring identifies and extracts a set of statements implementing a specific functionality within a method. Its application enhances the structure of code and provides improved readability and reusability. This paper introduces Segmentation, a new approach for identifying extract method opportunities focusing on achieving higher performance with fewer suggestions. Evaluation of the approach includes six case studies from the open-source domain, and performance is compared against two state-of-the-art approaches. The findings suggest that Segmentation provides improved precision and F measure over both the approaches. Further, improved performance is reflected over long methods too.
- Aharon Abadi, Ran Ettinger, and Yishai A Feldman. 2012. Fine Slicing. In Fundamental Approaches to Software Engineering. Springer, 471–485.Google Scholar
- Hiralal Agrawal, Richard A DeMillo, and Eugene H Spafford. 1993. Debugging with dynamic slicing and backtracking. Software: Practice and Experience 23, 6 (1993), 589–616.Google ScholarDigital Library
- Abdulaziz Alkhalid, Mohammad Alshayeb, and Sabri Mahmoud. 2010. Software refactoring at the function level using new Adaptive K-Nearest Neighbor algorithm. Advances in Engineering Software 41, 10 (2010), 1160–1178.Google ScholarDigital Library
- Amol Bhangdiya, Bikash Chandra, Biplab Kar, Bharath Radhakrishnan, KV Maheshwara Reddy, Shetal Shah, and S Sudarshan. 2015. The XDa-TA system for automated grading of SQL query assignments. In Data Engineering (ICDE), 2015 IEEE 31st International Conference on. IEEE, 1468–1471.Google ScholarCross Ref
- Sofia Charalampidou, Apostolos Ampatzoglou, Alexander Chatzigeorgiou, Antonios Gkortzis, and Paris Avgeriou. 2017. Identifying Extract Method Refactoring Opportunities based on Functional Relevance. IEEE Trans. Software Eng. 43, 10 (2017), 954–974.Google ScholarCross Ref
- Martin Fowler. 2009. Refactoring: improving the design of existing code. Pearson Education India.Google Scholar
- Jonathan L Gross, Jay Yellen, and Mark Anderson. 2018. Graph theory and its applications. Chapman and Hall/CRC.Google Scholar
- Hyeon Soo Kim, Yong Rae Kwon, and In Sang Chung. 1994. Restructuring programs through program slicing. International Journal of Software Engineering and Knowledge Engineering 4, 03(1994), 349–368.Google ScholarCross Ref
- Miryung Kim, Thomas Zimmermann, and Nachiappan Nagappan. 2012. A field study of refactoring challenges and benefits. In Proceedings of the ACM SIGSOFT 20th International Symposium on the Foundations of Software Engineering. ACM, 50.Google ScholarDigital Library
- Raghavan Komondoor and Susan Horwitz. 2000. Semantics-preserving procedure extraction. In Proceedings of the 27th ACM SIGPLAN-SIGACT symposium on Principles of programming languages. 155–169.Google ScholarDigital Library
- Raghavan Komondoor and Susan Horwitz. 2003. Effective, automatic procedure extraction. In 11th IEEE International Workshop on Program Comprehension, 2003. IEEE, 33–42.Google ScholarDigital Library
- Bogdan Korel and Juergen Rilling. 1998. Program slicing in understanding of large programs. In Program Comprehension, 1998. IWPC’98. Proceedings., 6th International Workshop on. IEEE, 145–152.Google ScholarCross Ref
- Arun Lakhotia and Jean-Christophe Deprez. 1998. Restructuring programs by tucking statements into functions. Information and Software Technology 40, 11 (1998), 677–689.Google ScholarCross Ref
- Martin Lippert and Stephen Roock. 2006. Refactoring in Large Software Projects.Google Scholar
- Chung-Horng Lung and Marzia Zaman. 2004. Using Clustering Technique to Restructure Programs.. In Software Engineering Research and Practice. 853–860.Google Scholar
- Katsuhisa Maruyama. 2001. Automated method-extraction refactoring by using block-based slicing. In Proceedings of the 2001 symposium on Software reusability: putting software reuse in context. 31–40.Google ScholarDigital Library
- Emerson R. Murphy-Hill, Chris Parnin, and Andrew P. Black. 2012. How We Refactor, and How We Know It. IEEE Trans. Software Eng. 38, 1 (2012), 5–18. https://doi.org/10.1109/TSE.2011.41Google ScholarDigital Library
- Danilo Silva, Ricardo Terra, and Marco Tulio Valente. 2014. Recommending automated extract method refactorings. In Proceedings of the 22nd International Conference on Program Comprehension. ACM, 146–156.Google ScholarDigital Library
- Danilo Silva, Nikolaos Tsantalis, and Marco Tulio Valente. 2016. Why we refactor? confessions of github contributors. In Proceedings of the 2016 24th ACM SIGSOFT International Symposium on Foundations of Software Engineering. ACM, 858–870.Google ScholarDigital Library
- Omkarendra Tiwari and Rushikesh K Joshi. 2020. Functionality Based Code Smell Detection and Severity Classification. In Proceedings of the 13th Innovations in Software Engineering Conference on Formerly known as India Software Engineering Conference. 1–5.Google ScholarDigital Library
- Nikolaos Tsantalis and Alexander Chatzigeorgiou. 2011. Identification of extract method refactoring opportunities for the decomposition of methods. Journal of Systems and Software 84, 10 (2011), 1757–1782.Google ScholarDigital Library
- Carmine Vassallo, Giovanni Grano, Fabio Palomba, Harald C Gall, and Alberto Bacchelli. 2019. A large-scale empirical exploration on refactoring activities in open source software projects. Science of Computer Programming 180 (2019), 1–15.Google ScholarDigital Library
- Mark Weiser. 1981. Program slicing. In Proceedings of the 5th international conference on Software engineering. IEEE Press, 439–449.Google ScholarDigital Library
- Baowen Xu, Zhenqiang Chen, and Hongji Yang. 2002. Dynamic slicing object-oriented programs for debugging. In Source Code Analysis and Manipulation, 2002. Proceedings. Second IEEE International Workshop on. IEEE, 115–122.Google Scholar
- Xia Xu, Chung-Horng Lung, Marzia Zaman, and Anand Srinivasan. 2004. Program restructuring through clustering techniques. In Source Code Analysis and Manipulation, 2004. Fourth IEEE International Workshop on. IEEE, 75–84.Google ScholarDigital Library
- Limei Yang, Hui Liu, and Zhendong Niu. 2009. Identifying fragments to be extracted from long methods. In Software Engineering Conference, 2009. APSEC’09. Asia-Pacific. IEEE, 43–49.Google ScholarDigital Library
Index Terms
- Identifying Extract Method Refactorings
Recommendations
Identification of Extract Method Refactoring Opportunities
CSMR '09: Proceedings of the 2009 European Conference on Software Maintenance and ReengineeringExtract Method has been recognized as one of the most important refactorings, since it decomposes large methods and can be used in combination with other refactorings for fixing a variety of design problems. However, existing tools and methodologies ...
A comprehensive review: Segmentation of MRI images-brain tumor
Segmentation of tumors in human brain aims to classify different abnormal tissues necrotic core, edema, active cells from normal tissues cerebrospinal fluid, gray matter, white matter of the brain. In existence, detection of abnormal tissues is easy for ...
A Novel Brain Tumor Segmentation from Multi-Modality MRI via A Level-Set-Based Model
Segmentation of brain tumor from magnetic resonance imaging is a challenging and time-consuming task due to the unpredictable appearance of tumor tissue in practical applications. In this paper we propose a novel level-set-based model for tumor ...
Comments