Why do you need to reconstruct it?

zhaozj2021-02-08  394

One of the factory in looking at this is why area we refactoring in the first

Place. One of My Concerns with MAAY Proponents of Lightweight Methods and

Refactoring (NOT ALL AS I TOO AM A Proponent of Refactoring and Lightweight

Methods) is what the the the refactoring is there

Needed. refactoring to fix "code smell" to my mind is because point didn't

Understand The Basics of Good Design in The First Place. To Write Great

Code, You Must Write Code That:

Runs all the tests.

2. Contains no duplication (once and only overce)

3. Expresss all the ideas you want to express.

a) Do Not Put The Implementation of Unreled Ideas in The Same

Method.

b) Classes Should Organize Ideas in a Readily Understandable Way.

c) Use appropriate name so you don't have to explain method, Member

OR Class Names with additional documentation

d) Methods and classes Should Be Implement So They Can Be

Understood Totally from their public interfaces. this not only allow

For Up-Front Testing, But Decreases Coupling.

4. Minimizes classes and methods. This is actually redundant, but is a

REMINDER THAT WE Are Trying to make this Simple and Concise

In My Mind, Refactoring Should Not Be Needed to Fix Code if you are

FOLLOWING THESE Rules. However, refactoring is definitely neseded to:

1) Fix Legacy Code ONCE YOUR Undering of Patterns Has Increased

2) Prepare Code for New Functions Resulting from Changing Requirements OR

The next development ity

转载请注明原文地址:https://www.9cbs.com/read-515.html

New Post(0)