Refactoring: Improving the Design of Existing Code (Object Technology Series) Hardcover – 28 Jun 1999
|New from||Used from|
- Choose from over 13,000 locations across the UK
- Prime members get unlimited deliveries at no additional cost
- Find your preferred location and add it to your address book
- Dispatch to this address when you check out
Frequently Bought Together
Customers Who Bought This Item Also Bought
Enter your mobile number below and we'll send you a link to download the free Kindle App. Then you can start reading Kindle books on your smartphone, tablet, or computer - no Kindle device required.
Getting the download link through email is temporarily not available. Please check back later.
To get the free app, enter your mobile phone number.
Your class library works, but could it be better? Refactoring: Improving the Design of Existing Code shows how refactoring can make object-oriented code simpler and easier to maintain. Today, refactoring requires considerable design know-how, but once tools become available, all programmers should be able to improve their code using refactoring techniques.
Besides an introduction to what refactoring is, this handbook provides a catalogue of dozens of tips for improving code. The best thing about Refactoring is its remarkably clear presentation, along with excellent nuts-and-bolts advice, from object expert Martin Fowler. The author is also an authority on software patterns and UML, and this experience helps make this a better book, one that should be immediately accessible to any intermediate or advanced object-oriented developer. (Just like patterns, each refactoring tip is presented with a simple name, a "motivation," and examples using Java and UML.)
Early chapters stress the importance of testing in successful refactoring. (When you improve code, you have to test to verify that it still works.) After the discussion on how to detect the "smells" of bad code, readers get to the heart of the book, its catalogue of more than 70 "refactorings"--tips for better and simpler class design. Each tip is illustrated with "before" and "after" code, along with an explanation. Later chapters provide a quick look at refactoring research.
Like software patterns, refactoring may be an idea whose time has come. This groundbreaking title will surely help bring refactoring to the programming mainstream. With its clear advice on a hot new topic, Refactoring is sure to be essential reading for anyone who writes or maintains object- oriented software. --Richard Dragan
Topics Covered: Refactoring, improving software code, redesign, design tips, patterns, unit testing, refactoring research and tools.
From the Back Cover
As the application of object technology--particularly the Java programming language--has become commonplace, a new problem has emerged to confront the software development community. Significant numbers of poorly designed programs have been created by less-experienced developers, resulting in applications that are inefficient and hard to maintain and extend. Increasingly, software system professionals are discovering just how difficult it is to work with these inherited, "non-optimal" applications. For several years, expert-level object programmers have employed a growing collection of techniques to improve the structural integrity and performance of such existing software programs. Referred to as "refactoring," these practices have remained in the domain of experts because no attempt has been made to transcribe the lore into a form that all developers could use. . .until now. In Refactoring: Improving the Design of Existing Code, renowned object technology mentor Martin Fowler breaks new ground, demystifying these master practices and demonstrating how software practitioners can realize the significant benefits of this new process.
With proper training a skilled system designer can take a bad design and rework it into well-designed, robust code. In this book, Martin Fowler shows you where opportunities for refactoring typically can be found, and how to go about reworking a bad design into a good one. Each refactoring step is simple--seemingly too simple to be worth doing. Refactoring may involve moving a field from one class to another, or pulling some code out of a method to turn it into its own method, or even pushing some code up or down a hierarchy. While these individual steps may seem elementary, the cumulative effect of such small changes can radically improve the design. Refactoring is a proven way to prevent software decay.
In addition to discussing the various techniques of refactoring, the author provides a detailed catalog of more than seventy proven refactorings with helpful pointers that teach you when to apply them; step-by-step instructions for applying each refactoring; and an example illustrating how the refactoring works. The illustrative examples are written in Java, but the ideas are applicable to any object-oriented programming language.See all Product Description
What Other Items Do Customers Buy After Viewing This Item?
Top Customer Reviews
Even better, I started to understand that there were a set of well-designed methods to apply, some of which I'd informally discovered for myself (so I wasn't alone after all) and many more that I hadn't thought of. It doesn't hurt that the book is well, and often entertainingly written.
Although some of the content is explicitly targeted at code built in full-blown object-oriented languages (the language used throughout is Java), it doesn't prove to be a hindrance to VB programmers like myself.
This book may fall slightly behind "Code Complete" in my list. Which would only make it the second best development book I've ever read (but it's the first one I felt like posting a review on).
It has an easily read and also sometimes quite amusing text, UML diagrams when necessary, and of course, VERY GOOD CONTENT !!! In short Refactoring is about turning badly designed and written code into well designed and written code, without breaking the program. If you liked read "Design Patterns" (Gamma et al.) you love this one as well. It's structured in much the same way.
The content covers
* WHY + WHEN to refactor
* HOW + WHAT to refactor
* A very good chapter on unit testing with JUnit (Open Source, by Eric Gamma (Design Patterns) and Kent Beck (Extreme Programming) )
* A thorough catalogue of different refactorings you can do to improve the design and readability of your code.
10 thumbs up for this book and the effect it will have on the industry.
1) People now talk about specific refactorings so, like design patterns, you need to know the names.
2) It was never supposed to teach you good design. If you want to learn that there are good books out there (including by Craig Larman and Robert C. Martin).
3) Some of it is basic but you can ignore that stuff if you want to, and when your doing some of the more complicated refactorings they could well be useful.
4) As Martin Fowler points out you don't need to read it cover to cover, in fact he advises you use it as a reference.
What this does teach you is how to iteratively improve bad code, something every developer needs to be able to do. In any case its valuable to read about the code smells, the reasons for needing to do specific refactorings and to read the examples.
Also if you want more advanced concepts I'd recommend "Agile Software Development" by Robert C. Martin and "Refactoring to Patterns" by Joshua Kerievsky which both build on this work.
Don't get me wrong, if a method name is unclear I'm all up for renaming it to something better. But do I really need to look up how to do it in a catalogue (which the author says is the main purpose of the book)? Or call it something fancy like "refactoring"? I've deliberately chosen the simplest example of course, but most refactorings are not much more complex: moving a method into another object, splitting a temporary variable into two, replacing a conditional with polymorphism, etc. Only one is a non-obvious enough idea that it gave me the "ooo" feeling that GoF generates throughout (introduce null object), and even that has simple enough mechanics that it's not something I would need to refer back to.
Some of the prose chapters were interesting when they drifted away from the main subject (especially the chapter about automated tests), which is why I've given two stars. However, if you're a professional programmer who enjoys a good read but in practice is more concerned with what will push forward your career, on both counts your time is better invested elsewhere.
Most Recent Customer Reviews
Amazing book with lots of examples and it is well written. Highly recommendedPublished 3 months ago by fokion sotiropoulos
Rewriting existing code used to be a scary business, mostly based on whim and talent.
Refactoring is a step-by-step process that guides code rewriting in a far more... Read more
One of the best book i have ever read!
Absolutely a master piece... every one should read it!
I find it amazing that this book was written more than 10 years ago and it still makes sense.. a lot. I read it a while back and I keep coming back to it. Read morePublished on 25 May 2014 by Amazon Customer
When buying this book I wasn't sure if it would be worth buying since most of the patterns are explained online, but after reading most of the book more than once I would recommend... Read morePublished on 26 Mar. 2014 by Mr G.
A widely regarded classic in the industry, and you can see why.
The first section presents a large refactoring exercise applied to a little movie rental application,... Read more
This is one of my all time favourite books.
It has helped me out on numerous occasions.
If your code has turned into a monster, this book is the light at the... Read more