Font Size: a A A

Design And Implementation Of Code Smell Detection Tool For Auto-refactoring

Posted on:2007-03-20Degree:MasterType:Thesis
Country:ChinaCandidate:J C LiFull Text:PDF
GTID:2178360215970130Subject:Software engineering
Abstract/Summary:PDF Full Text Request
At present refactoring technology is the most important method that guarantees the quality of software and lengthens the life of software. As an improving method of software, it can eliminate code smells or flaw in the software system, but the user scope of refactoring is extremely limited, one of reason is that detection of code smell is still completed manually in the preliminary stage of refactoring. The low efficiency restricted the application of refactoring.Firstly, in order to study code smell automatic detection, this paper analysed and discussed thoroughly code smell refactoring-based and the software metrics theory,and extended some new metrics method, produced the corresponding recognition methods according to the code smell performance symptom. In view of gainning more metrics information from the source code, we introduced the abstract syntax tree(AST) to take expresses the source code, for this, in the AST correlation theory foundation,we has carried on the design to the AST structure and node, and proposed new method of creating and traversing the AST.Secondly this paper illuminated the architecture of code smell detect tool for auto-refactoring which is integrated into Java IDE, and solved the extensible problem of code smell's detection ability preferably. In the process of designing and implementing the tool with the object-oriented method, we adopted many design patterns and some program techniques, ensured the rationality of implementation.Finally this paper tested and evaluated the code smell detection tool. Although the CSDT can merely detect thirteen code smells now and also has the certain distance to the automation and the intellectualization, it had carried on the significant attempt in the development plug-in unit type smell detection tool aspect, This tool has provided many conveniences for digital campus system development of National University of Defense Technology in refactoring work.
Keywords/Search Tags:Code Smell, Refactoring, Metrics, Abstract Syntax Tree, Design Patterns
PDF Full Text Request
Related items