TOC

This article is currently in the process of being translated into Korean (~25% done).

Introduction:

What is MVC?

MVC는 Model-view-controller(모델-뷰-컨트롤러)의 줄임말로, 그래픽 사용자 인터페이스(GUI)의 개발 초창기였던 1970년대에 개발된 소프트웨어 패턴입니다. MVC는 애플리케이션을 세 가지 영역으로 나누기 위해 노력합니다:

모델

모델은 데이터와 업무 로직이 저장되는 곳입니다. 예를 들어 전형적인 웹 애플리케이션에서는 데이터베이스 테이블이나 당신의 애플리케이션이 처리해야 하는 객체가 있습니다.

The View is the actual visual representation of your Model. In a typical web application, this would be the page that shows your Model to the user, whether it be a form for inputting the data or an output of the data or a combination of both. Obviously, a View doesn't have to show all parts of the Model, and a Model can have more than one View.

The Controller

The Controller should handle all communication between your Model and your View. In a typical web application, the methods of the Controller are invoked by the user when a page is loaded or a button is clicked. The Controller then updates the Model, if necessary, and then returns a new View (or action, but more about that later), if necessary.

MVC의 시작

1970년대에 처음 도입된 이래로, MVC 패턴은 30년 동안 많은 주목을 받지 못했었습니다. 초창기 펄이나, PHP, ASP 클래식 같은 초창기 웹 언어는 디자인 패턴에 별로 초점을 두지 않았었고, ASP.NET 출시 때만 해도 MVC는 ASP.NET에 포함되지 않았었습니다. 사실, MVC 기술을 당신의 프로젝트에적용할 수도 있었겠지만, 어떤 방법으로든 이 패턴을 권장하는 유명한 프레임워크는 없었습니다.

Then, in 2004, the Ruby on Rails framework was released, which was a web development framework based on the Ruby language with heavy inspiration from the MVC pattern. A lot of people believe that this put the focus back on MVC and shortly thereafter, many PHP frameworks, centered around the MVC pattern, was released. All of this made the MVC pattern hugely popular, which is probably why Microsoft decided to do an implementation of it for their .NET framework, including massive tool support in their Visual Studio IDE. ASP.NET MVC was released in 2007, but the first final version didn't see the light of day before 2009.

In the next chapters, we will look deeper into what ASP.NET MVC is all about and how it compares to the alternatives, mainly ASP.NET WebForms.


This article has been fully translated into the following languages: Is your preferred language not on the list? Click here to help us translate this article into your language!