Switch Statement

This smell occurs when switch statements that switches on type codes are spread across the software system instead of exploiting polymorphism.

Related smells: Unexploited Encapsulation Missing Hierarchy Type Queries

Reference

M. Fowler, “Refactoring: Improving the Design of Existing Code”. Addison-Wesley, 1999.


Design Smells

Home

All rights reserved (c) Tushar Sharma 2017-23.