aspose file tools*
The moose likes OO, Patterns, UML and Refactoring and the fly likes Can refactoring be considered a form of encoding? Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Engineering » OO, Patterns, UML and Refactoring
Bookmark "Can refactoring be considered a form of encoding?" Watch "Can refactoring be considered a form of encoding?" New topic
Author

Can refactoring be considered a form of encoding?

Jay Orsaw
Ranch Hand

Joined: Jun 14, 2011
Posts: 356

So I am doing a report on Encoding and reading up it keeps making me think of re-factoring when I read stuff like it can reconstruct code, or change size and such. Encoding itself is normally going from 1 form of code like text to a coded from like binary, but when I read up about "re-encoding" it seems ike it would be refactoring itself... Thoughts?
Jelle Klap
Bartender

Joined: Mar 10, 2008
Posts: 1760
    
    7

I don't see how the two concepts are related.
To view refactoring as re-encoding the functional aspects / behavior of a body of source code in a different structure is kind of a stretch, in my opinion.
What would the equivalent of decoding be in that scenario? Restoring the previous revision from a version control system?


Build a man a fire, and he'll be warm for a day. Set a man on fire, and he'll be warm for the rest of his life.
Bear Bibeault
Author and ninkuma
Marshal

Joined: Jan 10, 2002
Posts: 61001
    
  65

Sort of like asking if chile plants are like stratocumulus clouds.


[Asking smart questions] [Bear's FrontMan] [About Bear] [Books by Bear]
Paul Clapham
Bartender

Joined: Oct 14, 2005
Posts: 18541
    
    8

I'm not sure that Jay's understanding of refactoring is the same as you two's understanding. To me, and probably to you as well, refactoring is where I look at my code and decide that parts of it need to be rewritten or redesigned or restructured to improve some aspect of the code. Whereas Jay seems to have read something which implies

it can reconstruct code


which sounds like it refers to some automated process, rather than something a programmer does. So I think that we're talking at cross-purposes here.
Bear Bibeault
Author and ninkuma
Marshal

Joined: Jan 10, 2002
Posts: 61001
    
  65

Perhaps -- it'd certainly explain the disconnect. So Jay, what is it that you mean by "refactoring"?
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: Can refactoring be considered a form of encoding?