(object-oriented, programming)
Improving a computer program by reorganising its internal structure without altering its external behaviour.

When software developers add new features to a program, the code degrades because the original program was not designed with the extra features in mind.

This problem could be solved by either rewriting the existing code or working around the problems which arise when adding the new features. Redesigning a program is extra work, but not doing so would create a program which is more complicated than it needs to be. Refactoring is a collection of techniques which have been designed to provide an alternative to the two situations mentioned above.

The techniques enable programmers to restructure code so that the design of a program is clearer. It also allows programmers to extract reusable components, streamline a program, and make additions to the program easier to implement.

Refactoring is usually done by renaming methods, moving fields from one class to another, and moving code into a separate method.

Although it is done using small and simple steps, refactoring a program will vastly improve its design and structure, making it easier to maintain and leading to more robust code.

"Refactoring, Reuse & Reality" by Bill Opdyke.

"Refactoring, a first example" by Martin Fowler.
This article is provided by FOLDOC - Free Online Dictionary of Computing (


To improve the quality of code in a program. Refactoring does not alter the functionality of the software; but makes it more readable and maintainable for future changes.
Copyright © 1981-2019 by The Computer Language Company Inc. All Rights reserved. THIS DEFINITION IS FOR PERSONAL USE ONLY. All other reproduction is strictly prohibited without permission from the publisher.
References in periodicals archive ?
Developers seeking to leverage Service Mesh to accelerate refactoring applications using microservices will find Red Hat's experience in hybrid cloud and Kubernetes a reliable partner with the Service Mesh solution.
By deepening staff and company capabilities around refactoring applications for modern cloud-based architectures, in particular, within Azure, DevOps enablement and consulting, and analytics-driven software development, Green House Data is now uniquely suited to deliver comprehensive IT modernisation and IT management.
As a result, when shifting or bursting on-premises workflows to cloud, organizations need cloud-based file storage to deliver native compatibility...thus eliminating the need for costly, time-consuming application refactoring.
NFS), with no need for OS kernel modifications or client-side software installs, Elastifile provides native compatibility with existing applications and workflows, eliminating the need for costly refactoring projects.
dbForge SQL Complete is an add-in for SQL Server Management Studio and Visual Studio with fully-featured tools designed to speed up SQL code writing, offer context-based smart suggestions, perform automatic formatting and refactoring, improve code readability, increase productivity, and lower costs.
The tribally owned company is refactoring the software to best practice and tested development standards that leverage modern object-oriented practices.
A member of the data analytics research group, Ajienka's research interests include data-driven object-oriented software engineering, including software maintenance, quality, change impact analysis and refactoring.
When management assumes refactoring is "not their problem," such unaddressed work remains an organizational problem, and organizationally, there are already enough problems.
Such refactoring is needed, but often deferred due to code complexity, which over time can result in technical debt for the system.
improved IntelliSense; streamlined refactoring, code-fixing and debugging
After an introduction to Scala, it covers the basics of object-orientation and software development, object-orientation in Scala, abstraction and polymorphism, GUIs (graphical user interfaces) and graphics, other collection types, stacks and queues, multithreading and concurrency, low-level multithreading and Java libraries, stream input/output and XML, networking, linked lists, priority queues, refactoring, recursion, trees, regular expressions and context-free parsers, binary heaps, direct access binary files, spatial trees, augmenting trees, and hash tables.