: Monday Morning Tutorials (8:30 - 12:00) : Eclipse : Agile Development : Monday : Programming Techniques
Merciless Refactoring with Eclipse
Pacific Salon 6
Monday, 8:30, half day
Martin Lippert, it-agile GmbH
Tutorial number: 26
The goal of the tutorial is to provide an insight how the refactoring support that is built into the Eclipse IDE can be utilized to do merciless refactoring in a safe way. This includes:
- Small refactorings and their usage via keystrokes. This shows how refactorings like "Extract Local Variable", "Convert Local Variable into Field" or "Rename" can be used via simple keystrokes to support even simplest programming tasks.
- Changing method signatures via the proper refactoring feature to automatically adapt all callers.
- Using "Inline Method" to remove deprecated method calls.
- Split up larger refactorings by combined smaller ones. E.g. replace a constructor with a different one by combining "Introduce Factory" and "Inline Method".
- Pushing around classes with drag & drop techniques until a clean package structure is achieved. We demonstrate how this cleanup process can be supported by XRadar, a code report tool. XRadar generates a graphical architecture view depicting architectural violations. By pushing the classes into the appropriate packages the graphical view will show the progress.
Examples for the refactorings are taken from the books by Martin Fowler, Joshua Kerievsky and William Wake.
Beginner: Attendees must have a solid understanding of object-orientation. Basic understanding of refactoring or Eclipse is not required.
Martin Lippert, it-agile GmbH: Martin Lippert is a consultant and coach for software engineering technology and agile development methods. He focuses on software development on top of the Eclipse platform, refactoring, extreme programming and aspect-oriented programming. He worked for the AspectJ project at PARC as an intern during the summer of '99 and has given a number of talks, tutorials and demonstrations on various topics of software engineering at international conferences. He is co-author of the upcoming book on complex refactorings in large software projects that will be published by Wiley in October.