CollapseHierarchy
Last edit November 17, 2003
See
http://www.refactoring.com/catalog/collapseHierarchy.html
This refactoring merges a superclass and subclass into a single class.
It is used when one of those classes provides little value. This condition occurs when a developer pre-emptively designs a deep class hierarchy or after other refactorings have moved most of the functionality out of one of the classes.
This refactoring uses the refactorings
PullUpField
,
PullUpMethod
,
PushDownMethod
,
PushDownField
.
See
MaxThreeLayersOfInheritance
CategoryRefactoring