SOLID & OOP Principles (50 Qs)•Part 2: Object-Oriented Design, Code Smells & Refactoring (11 - 24)
How do you identify the "God Object" Code Smell and how do you refactor it using SRP?
mid Levelsolid-principlesObject-Oriented Design
In Simple Words: A God Object knows too much or does too much (thousands of lines, dozens of dependencies). Refactor by grouping methods around distinct business actors and extracting cohesive single-purpose classes.