Quicktostudy
Contact Us| About Us| Terms| Privacy Policies
Dot Net MVC Tutorial
Home »  Dot Net MVC Tutorial »  Asp Net MVC Architecture

Asp Net MVC Architecture

Asp.Net MVC Architecture

The Model View Controller (MVC) architectural pattern separates an application into three main components : Model , View, controller.

Model

Model is responsible for actual data processing, like database connection, querying database, implementing business rules etc. It feeds data to the view without worrying about the actual formatting and look and feel. Data provided by Model is display-neutral so it can be interfaced with as many views without code redundancy; this eases your code maintenance and reduces bugs and allows code reuse at good extent. Model responds to the request made by controllers and notifies the registered views to update their display with new data.

View

View is the graphical data presentation (outputting) irrespective of the real data processing. View is the responsible for look and feel, some custom formatting, sorting etc. View is completely isolated from actual complex data operations. For example, Online product catalog view is completely separated from database connection, query, tables etc. It simply gets final row-data from the model and puts some cosmetics and formatting before displaying it in browser. View provides interface to interact with the system. The beauty of MVC approach is that it supports any kind of view, which is challenging in todays distributed and multi-platform environment.

A MVC model can have multiple views, which are controlled by controller. View interface can be of WEB-FORMS, HTML, XML/XSLT, XTML, and WML or can be Windows forms etc.

Controller

Controller is responsible for Notice of action. Controller responds to the mouse or keyboard input to command model and view to change. Controllers are associated with views. User interaction triggers the events to change the model, which in turn calls some methods of model to update its state to notify other registered views to refresh their display.

Asp.Net MVC Architecture

Model : Model is a set of classes that describes the data we are working with as well as the business rules for how the data can be changed and manipulated.
View : View defines how the application UI (User Interface) will be displayed.
Controller : Controller is a set of classes that handles communication from the user, overall application flow and application specific logic.

Asp.Net MVC Architecture
Contact Us| About Us| Terms| Privacy Policies
Powered by Lorquins Technologies© 2017 QuickToStudy.com. All Rights Reserved