Learn MVC Architecture for UI Designing

Chethani Dilhari
LinkIT
Published in
2 min readJun 4, 2021

--

source: dreamstime.com

This article is about a famous user interface design model called MVC architecture. I describe it simply with examples for you to read and learn about it easily.

MVC architecture is a standard application design model which is used to develop modern user interfaces. It consists of three interconnected components which are used to handle specific aspects of an application. Those interconnected components are model, view, and controller.

Model
Model component maintains all data and logic used by the application. It works directly with the database but not with the user interface. Model objects are used to retrieve, update, delete or store data in a database.

View
The view is used to display objects. It acts as the user interface and deals with UI components of a particular object. The user can perform actions using these views. Views can contain markup languages such as HTML, CSS, JS, XML etc.

Controller
The controller acts as a request handler as it handles user requests. Users can send URL requests via views and those requests are handled by the controller. It sends a relevant view with model data as the response and updates the database with the model.

Usage of MVC Architecture

MVC architecture is famous for design both web applications and mobile applications. There are so many MVC frameworks that are used to design them, as follows. 

source: etutorialspoint.com
  1. Ruby on Ralls 
  2. CakePHP
  3. Django 
  4. Yii 
  5. SpringMVC 
  6. CherryPy 
  7. Catalyst 

Advantages of MVC Architecture

  • Applications can be developed in less time
  • Allow multiple developers to collaborate and work together. 
  • Updating the application is easy. 
  • Debugging is easy as there are multiple levels. 
  • Testing can be done separately for each component. 
  • Reduce complexity and allow to development of multiple components parallel.

    Disadvantages of MVC Architecture
  • Difficult to understand and reuse the model. 
  • Formal validation is not supported. 
  • Difficult to use MVC architecture with modern user interfaces that may include dynamic and complex presentation of data. 
  • It is hard to coordinate among multiple programmers when developing parallel MVC applications. 
  • Developers might need knowledge of multiple technologies.

I hope you learned about MVC architecture and this will be helpful in your software engineering career.

Thank you for reading…

--

--

Chethani Dilhari
LinkIT

Final year IT undergraduate in University of Moratuwa