Refactoring is the process of improving the existing system design without changing its behavior.
Besides Martin Fowler's seminal book "Refactoring - Improving the design of existing code" and Joshua Kerievsky's book "Refactoring to Patterns", are there any good resources on refactoring?
One should not start refactoring unless he has a clear purpose in mind. Once the purpose has been accomplished, one is done. There is probably not an explicit 10 point check list to tell you when you are done, but most people can determine if they are being productive or just playing.
Code refactoring is not just a bug-removal process. Its main purpose is to improve readability and systematically boost application code performance. And even though the primary intention of code refactoring isn't to reduce or eliminate bugs, it does help prevent bugs in the long run.
For many developers, the best moment to refactor is before working on a new version of the software or before adding new functionality. Cleaning up the code before adding new features to it improves the quality of the product itself and makes the job easier for other developers.
http://www.refactoring.com/ might help you. They have a long list of methods here:
Joel's article Rub a dub dub shows you why you should refactor and not rewrite (but I guess you already knew that rewriting is a thing you should never do..)
Working Effectively with Legacy Code focuses on dealing with existing code-bases that need to evolve to be testable. Many techniques are used in the book to accomplish this, and is an excellent resource for refactoring.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With