Duplicate Feature | |||
| |||
Context: When the uniqueness of a feature implementation adds undesirable coupling among components the disadvantages of its uniqueness can outweigh those of having the feature duplicated. In such cases it makes sense to duplicate the feature implementation during the course of the ongoing refactoring. The Duplicate Feature refactoring makes a trade: It removes the undesired dependency at the cost of duplication. Doing so allows to proceed with the dependency problem but leaves the duplication smell to be resolved by later refactorings such as Eliminate Duplication By Composition and Eliminate Duplication By Inheritance. See also: Pull Up Feature, Push Down Feature, Introduce Duplication |