0% found this document useful (0 votes)
20 views

Model

MVC is an architectural design pattern that separates software into three components: the model, the view, and the controller. The model manages the data, the view displays the data, and the controller handles input and logic. Using MVC provides benefits like organizing large applications, supporting asynchronous methods, being easily modifiable, and faster development.

Uploaded by

fatma ashraf
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
20 views

Model

MVC is an architectural design pattern that separates software into three components: the model, the view, and the controller. The model manages the data, the view displays the data, and the controller handles input and logic. Using MVC provides benefits like organizing large applications, supporting asynchronous methods, being easily modifiable, and faster development.

Uploaded by

fatma ashraf
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 3

MVC

is an architectural design pattern that separates


- software business logic.
- view.

1. Model –
This level is considered the lowest level when compared with the View and
Controller. It primarily represents the data to the user and defines the storage
of all the application’s data objects.

2. Views –
This level is majorly associated with the User Interface(UI) and it is used to
provide the visual representation of the MVC model. In simpler terms, this
level deals with displaying the actual output to the user. It also handles the
communication between the user (inputs, requests, etc.) and the controller.

3. Controller –
This level takes care of the request handler. It is often considered as the
brain of the MVC system- a link, so to speak, between the user and the
system. The controller completes the cycle of taking the user output,
converting it into desired messages, and passing them on to the views(UI).
Benefits of MVC
● Organizes large-size web applications –
As there is segregation of the code among the three levels, it becomes extremely
easy to divide and organize web application logic into large-scale applications (which
are required to be managed by large teams of developers). The major advantage of
using such code practices is that it helps to find specific portions of code quickly and
allows the addition of new functionality with ease.

● Supports Asynchronous Method Invocation (AMI) –


Since the MVC architecture works well with JavaScript and its frameworks, it is no
surprise that it also supports the use of Asynchronous Method Invocation (AMI),
allowing developers to build faster loading web applications. It means that MVC
applications can be made to work even with PDF files, site-specific browsers, and
also for desktop widgets.

● Easily Modifiable –
Using the MVC methodology allows easy modification of the entire application.
Adding/updating the new type of views is simplified in the MVC pattern (as a single
section is independent of the other sections). So, any changes in a certain section of
the application will never affect the entire architecture. This, in turn, will help to
increase the flexibility and scalability of the application.

● Faster Development Process –


As there is segregation of the code among the three levels, developing web
applications using the MVC model allows one developer to work on a particular
section (say, the view) while another can work on any other section (say, the
controller) simultaneously. This allows for easy implementation of business logic as
well as helps to accelerate the development process fourfold. It has been observed
that when compared to other development models, the MVC model ends up showing
higher development speeds (up to three times).

● Easy planning and maintenance –


The MVC paradigm is helpful during the initial planning phase of the application
because it gives the developer an outline of how to arrange their ideas into actual
code. It is also a great tool to help limit code duplication, and allow easy maintenance
of the application.

● Returns data without formatting –


By returning un-formatted data, the MVC framework empowers you to create your
own view engine. For example, any type of data can be formatted using HTML, but
with the MVC framework, you can also format the data using the Macromedia Flash
or Dream viewer. It is helpful for the developers because the same components can
be re-used with any interface.

● Supports TTD (test-driven development) –


A major advantage of the MVC pattern is that it simplifies the testing process by a
great deal. It makes it easier to debug large-scale applications as multiple levels are
structurally defined and properly written in the application. Thus making it trouble-free
to develop an application with unit tests.

● Multiple Views –
In the MVC architecture, developing different view components for your model
component is easily achievable. It empowers you to develop different view
components, thus limiting code duplication as it separates data and business logic.

● SEO-Friendly Platform – (Search Engine Optimization)


The MVC platform hugely supports the development of SEO-friendly web
applications. To generate more visits from a particular application, MVC provides an
easy way out to develop SEO-friendly RESTful URLs.

SEO-Friendly Platform meaning


Making a website SEO-friendly means that Google and other search engines can
crawl each page on the website efficiently, interpret the content effectively, and index it in
their database. Once indexed, they can then serve the most relevant and valuable web
pages to their users based on the topics they search for.

You might also like