Well, i keep hearing that you better not get use of static methods in php, i can understand that to some extent, But there are some confusions for me, what i want to know is :
Let's say i'm writing an application, i define hundreds of classes ( Or use a framework which already contains hundreds of different classes ), i don't know if i should create a class for each small task, so lets say i create a class for handling all CRUD tasks for a particular item ( for example blog posts ), and this class handles viewing, saving, editing and etc, in such case, if i instantiate the class each time, it will create an object containing mostly methods that we don't need in that request, so... I guess what i'm trying to ask is:
Is it wise to do something like that? Create classes containing methods a lot of them we don't use in each request, and define them as non-static, so each time we'd have to instantiate the whole object?
Like Laravel does for it's controllers, we define all non-static methods to handle all tasks related to a certain route group, and instantiate the whole controller each time we want to access one or two of those methods.
Thanks in advance for your time and patience. I appreciate it.