FONT face, Verdana, YU Dong-qi, et al. ObjectOriented Program Method Level Clone Detection Based on Similarity Measurement[J]. Acta Electronica Sinica, 2010, 38(2A): 174-181.
DOI:
FONT face, Verdana, YU Dong-qi, et al. ObjectOriented Program Method Level Clone Detection Based on Similarity Measurement[J]. Acta Electronica Sinica, 2010, 38(2A): 174-181.DOI:
ObjectOriented Program Method Level Clone Detection Based on Similarity Measurement
<FONT face=Verdana>Code clone detection is important for refactoring and extraction of reusable assets.The present code clone detection method is on the basis of detection of similar code segments
which brings difficulty for further clone analysis and refactoring.Aiming at this problem
this paper offers a method level clone detection method for object-oriented program based on similarity measurement
which detects method level cloned code.Our method utilizes comments of the code
method signature and syntactic similarity to measure the degree of the clone.Based on the method mentioned above
further refactoring can be realized by combining similar methods of subclasses into one method and pulling it up into superclass.Our method’s effectiveness has been verified by analyzing the result of the experiment on the code of JDK.The initial experiment result shows that our method canhelp developer detect method level code clone both accurately and effectively.