Model View Controller (MVC) Architecture

Model View Controller (MVC) Architecture


Posted in : Java Posted on : August 29, 2011 at 4:52 PM Comments : [ 0 ]

In this section, you will learn about Model View Controller(MVC) Architecture.

Model View Controller (MVC) Architecture

In this section, you will learn about Model View Controller(MVC) Architecture.

Model

In MVC, model provide an interface to manage the behavior and data of the application. Due to this the controller don't need code to manipulate application's data. Instead it contact with model and request for data access and manipulation and model perform manipulation or data access. In this way, we can say that MVC provide Business logic.

View

In the MVC architecture, view is used to return response to the web browser. So what ever a user sees is due to view. Generally , we use JSPs or HTML pages for view. The advantage of view is that you can use any view technology without effecting the Model/Business layer of your application

Controller

Controller is the nucleus of the MVC framework. Typically, a Controller is a servlet that receive and process the request appropriately and also manages the data flow between Model layer and View layer. In other words, you can say that it controls over how Model and View layer communicates .

Complete Process

Given below the MVC architecture :

First, a web browser make a request which is processed by Controller. Controller also do validation if require. Further it interact with Model requesting for data(If needed). At last it interact with View , which in turn send response back to the web browser.

 

Go to Topic «PreviousHomeNext»

Your Comment:


Your Name (*) :
Your Email :
Subject (*):
Your Comment (*):
  Reload Image
 
 

 
Tutorial Topics