The program dependence graph and its use in optimization
ACM Transactions on Programming Languages and Systems (TOPLAS)
Design patterns: elements of reusable object-oriented software
Design patterns: elements of reusable object-oriented software
Refactoring: improving the design of existing code
Refactoring: improving the design of existing code
An Automated Refactoring Approach to Design Pattern-Based Program Transformations in Java Programs
APSEC '02 Proceedings of the Ninth Asia-Pacific Software Engineering Conference
A Methodology for the Automated Introduction of Design Patterns
ICSM '99 Proceedings of the IEEE International Conference on Software Maintenance
A Survey of Software Refactoring
IEEE Transactions on Software Engineering
Representing and querying histories of semistructured databases using multidimensional OEM
Information Systems - Special issue: ADBIS 2002: Advances in databases and information systems
Refactoring to Patterns
Head First Design Patterns
Toward an Implementation of the "Form Template Method" Refactoring
SCAM '07 Proceedings of the Seventh IEEE International Working Conference on Source Code Analysis and Manipulation
IEEE Transactions on Software Engineering
The art of agile development
Identification of refactoring opportunities introducing polymorphism
Journal of Systems and Software
A logic based approach to locate composite refactoring opportunities in object-oriented code
AQTR '10 Proceedings of the 2010 IEEE International Conference on Automation, Quality and Testing, Robotics (AQTR) - Volume 03
Optimized traffic flow assignment in multi-homed, multi-radio mobile hosts
Computer Networks: The International Journal of Computer and Telecommunications Networking
Identification of extract method refactoring opportunities for the decomposition of methods
Journal of Systems and Software
Hi-index | 0.00 |
Context: The automated identification of code fragments characterized by common design flaws (or ''code smells'') that can be handled through refactoring, fosters refactoring activities, especially in large code bases where multiple developers are engaged without a detailed view on the whole system. Automated refactoring to design patterns enables significant contributions to design quality even from developers with little experience on the use of the required patterns. Objective: This work targets the automated identification of refactoring opportunities to the Strategy design pattern and the elimination through polymorphism of respective ''code smells'' that are related to extensive use of complex conditional statements. Method: An algorithm is introduced for the automated identification of refactoring opportunities to the Strategy design pattern. Suggested refactorings comprise conditional statements that are characterized by analogies to the Strategy design pattern, in terms of the purpose and selection mode of strategies. Moreover, this work specifies the procedure for refactoring to Strategy the identified conditional statements. For special cases of these statements, a technique is proposed for total replacement of conditional logic with method calls of appropriate concrete Strategy instances. The identification algorithm and the refactoring procedure are implemented and integrated in the JDeodorant Eclipse plug-in. The method is evaluated on a set of Java projects, in terms of quality of the suggested refactorings and run-time efficiency. The relevance of the identified refactoring opportunities is verified by expert software engineers. Results: The identification algorithm recalled, from the projects used during evaluation, many of the refactoring candidates that were identified by the expert software engineers. Its execution time on projects of varying size confirmed the run-time efficiency of this method. Conclusion: The proposed method for automated refactoring to Strategy contributes to simplification of conditional statements. Moreover, it enhances system extensibility through the Strategy design pattern.