The problem of defining appropriate classes for your project is generally non-trivial.
If we need to define a class representing, for example, students, we should consider:
What shall we call it?
What are its attributes?
What methods are needed to implement behaviours according to their roles?
We also need to consider what objects will be interacting with objects of the Student class, and what type of interaction is the most appropriate.
Are Student objects used by objects of other classes?
Are Student objects used by functions outside the class?
A scenario to think about:
What objects are needed and what are their properties?
Cat, mat
Data?
Big -> Size? Width, Height, Depth?
Heavy Mass
Orange Colour (Ginger?)
Methods/Behaviours?
Measure -> Size Test for “bigness”
Measure -> Mass Test for “heaviness”
Show colour
Sitting on the mat (interaction)
Behaviours?
Can be sat on