How Many Classes Are Needed? Many,simple classes means that each class Encapsulates less of the overall system intelligence Is more reusable Is easier to implement A few,complex classes means that each class ■ Encapsulates a large portion of the overall system intelligence Is less likely to be reusable Is more difficult to implement A class should have a single well-focused purpose.A class should do one thing and do it well! Object Oriented Analysis and Design 7Object Oriented Analysis and Design 7 A class should have a single well-focused purpose. A class should do one thing and do it well! How Many Classes Are Needed? Many, simple classes means that each class ▪ Encapsulates less of the overall system intelligence ▪ Is more reusable ▪ Is easier to implement A few, complex classes means that each class ▪ Encapsulates a large portion of the overall system intelligence ▪ Is less likely to be reusable ▪ Is more difficult to implement