MVC, in the M layer building class, C layer new corresponding class of objects, and then to the V Layer, V layer using the object calls the corresponding class method, have you seen this mode?
Reply content:
MVC, in the M layer building class, C layer new corresponding class of objects, and then to the V Layer, V layer using the object calls the corresponding class method, have you seen this mode?
MVC generally on the M-layer is the data model, the operation method or something. The C layer is responsible for invoking the M-layer stuff and collating the data. V-Layer Data final data:
But! Each company's code habits are different and will not strictly abide by this. It's like you said. In m building the data object, in C just instantiating the object, the V layer is specifically called, I have seen in a few days similar code style, is also allowed. So nothing ~ just follow the rules of the unified to write on the line.
I've also seen m just declaring data, C going to manipulate the data, v processing + output mode. The writing is also very handy. Key look at the company's