Open Source

Model View Controller

Model View Controller or MVC is a programming pattern that allows for the separation of data and user interface (presentation) aspects of an application. MVC web application development India helps in the structuring of the code in order to ensure that the changes made in the way the data is handled and organized does not effect the user interface and vice versa.

Components

The architecture is made up of three components. These include the following:

Model

The Model component contains the data and the business logic of the application. In MVC, the Model is independent of the View and Controller. In order to be independent, the Model cannot directly refer to the View and Controller. Models can be of the following types:

  • Active: In an Active Model changes made in the model are immediately notified to the Controller and View.
  • Passive: In a Passive Model changes are not notified to the Controller or View. In case the Controller processes a request that changes the Model and affects the View, the Controller sends a notification of the same to the View. The View can then obtain the updated data from the Model.

View

This is user interface of the application. It renders the information obtained from data model. The View can access the Model only to read the data, it cannot make any changes to the Model.

Controller

The Controller is the component that receives and processes inputs sent by a user. Based on the type of requests sent, the Controller will send requests to the Model and View. The Controller can change the state of the Model.

Benefits of MVC

The MVC Architecture offers the following benefits:

  • The data and presentation are separate
  • Program codes can be re-used
  • Multiple versions of the User Interface can be created
  • Developers can focus on a specific area (i.e. user interface / business logic) without having to worry about the other.

Recommendations

We enagaed with Icreon in the summer of 2009 to build a new aspect for our Saddlery company, the brief was to come up with a suitable adaptable ecommerce solution and also a community site for members. We had unfourtnately engaged a cheap off the shelf solution prior to talking with Icreon. After quickly working out that the off the shelf solution would not work, Our in house designers and Icreon set to work to remake the project. In my opinion I have never been more impressed by a company.


John Colville
Joust John Colville