Alonso and All --

  What has helped me immensely to understand this subject is Fowler, M. (2019). 
Refactoring: Improving the Design of Existing Code (2nd).  

  -- Chris

----- Original Message -----
From: "Alonso Del Arte" <alonso.dela...@gmail.com>
To: "NetBeans Mailing List" <users@netbeans.apache.org>
Sent: Monday, August 21, 2023 5:47:41 PM
Subject: Re: Refactoring

Refactoring usually involves making multiple changes in multiple files. For
example, in a Java project, say you decide to rename the MoneyAmount class
to just Money. If that class is referenced by a dozen other classes and
interfaces, then the change will impact at least a dozen lines in other
classes and probably several lines in the class being refactored.

Before IDEs like NetBeans, you would have had to hunt down each of those
references and change them one by one, or else try to compile and then
scrutinize the error messages. Now with NetBeans, you can just rename in
one place and have NetBeans take care of the rest.

Another kind of refactoring that might be applicable to your projects is
moving things from one folder to another. Like for example if you
mistakenly put a style sheet in the JavaScript folder.

Al

On Mon, Aug 21, 2023 at 6:27 PM Owen Thomas <owen.paul.tho...@gmail.com>
wrote:

> Hi Tom.
>
> Refactoring is simply moving stuff around in your source code without
> making any (major) change to the functionality of your program.
>
> You may want to do this when for instance you are preparing to implement a
> functional enhancement that makes use of a particular design pattern, and
> your source code cannot implement the functional enhancement in its current
> state.
>
> HTH.
>
>   Owen.
>
> On Tue, 22 Aug 2023 at 07:28, Tom Rushworth <tjr...@twc.com> wrote:
>
>> Newbie question.  I'm working on an HTML project.  When I change a file
>> name, Netbeans wants to know if I want to "refactor" or not. What does
>> it mean to refactor?
>>
>>
>> ---------------------------------------------------------------------
>> To unsubscribe, e-mail: users-unsubscr...@netbeans.apache.org
>> For additional commands, e-mail: users-h...@netbeans.apache.org
>>
>> For further information about the NetBeans mailing lists, visit:
>> https://cwiki.apache.org/confluence/display/NETBEANS/Mailing+lists
>>
>>

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscr...@netbeans.apache.org
For additional commands, e-mail: users-h...@netbeans.apache.org

For further information about the NetBeans mailing lists, visit:
https://cwiki.apache.org/confluence/display/NETBEANS/Mailing+lists

Reply via email to