Controller: - The controller is like a traffic cop.Whenever user requests any resource it first goes to the controller. Controller than interact with both the Model and View.
is the part of the application that handles user interaction.
Typically controllers read data from a view, control user input, and send input data to the model.
Typically controllers read data from a view, control user input, and send input data to the model.
The MVC separation helps you manage complex applications, because you can focus on one aspect a time. For example, you can focus on the view without depending on the business logic. It also makes it easier to test an application.
The MVC separation also simplifies group development. Different developers can work on the view, the controller logic, and the business logic in parallel.
Model: - The model is responsible for the data for the application and also it creates data for the view. It handles data processing and database works part.
the part of the application that handles the logic for the application data.
Often model objects retrieve data (and store data) from a database.
the part of the application that handles the logic for the application data.
Often model objects retrieve data (and store data) from a database.
View: - It is a presentation layer i.e. it shows the data to the users.
is the parts of the application that handles the display of the data.
Most often the views are created from the model data.
is the parts of the application that handles the display of the data.
Most often the views are created from the model data.
No comments:
Post a Comment