SlideShare uma empresa Scribd logo
1 de 14
Baixar para ler offline
• Software architecture pattern that separates the model,
the user interface and control logic of an application in
three distinct components.
• MVC proposes the construction of three distinct components. One side
for the representation of information, and on the other hand for user
interaction.

One model

Many Views

Many Controllers
The Model
Representation of domain data.
Business logic
Persistence mechanism

The View
User Interface
Interaction elements

The Controller
Intermediary between Model and View
It maps user actions – model actions
Select the view and provide
information to itself
It is the specific representation of the
information with which the system
operates. Logic ensures the integrity of
data and allows to derive it.
Represents the model in a suitable format to interact and access the data,
usually called "User Interface" (GUI Java, HTML, XML).
It is the link between the view and the model, is responsible for receiving
and responding to events, typically user actions and invokes changes on
the model and probably in the view.
• Organization
• Rapid Application Development
• Reusing Code
• Parallel development
• It presents the same information in different ways.
• The views and application behavior should reflect the
manipulations of the data immediately.
• It allows different user interface standards or port it to other
environments where the application code should not be
affected.
• This model is not new, it was introduced in 1987 in the Smalltalk
programming language.
• With the boom of Web applications, it has proven to be a
programming mode that fits quite well with the internet, being
both the model and the controller executed server side, and the
view on the client side executed.
Control Flow
1.
2.
3.
4.

5.

The user performs an action on the interface.
The controller takes the input event.
The controller notifies the user action to the model,
which may involve a change of state of the model.
It generates a new view. The view takes the data
model.
The user interface waits for another user interaction,
which starts a new cycle.
Controller updates the
model
View alerts controller of a
particular event

View grabs model data and
updates itself

User interacts with a
view

Model alerts view that it has
changed
• It applies to all types of systems
• And technologies (Java, Ruby, Python, Perl, Flex, SmallTalk,. Net, etc..)
• Model: The model is made by the developer.
• View: Set of objects of classes that inherit from
java.awt.Component.
• Controller: The controller is the event processing thread, which
captures and propagates the event to the view and the model.
Treatment classes of events (sometimes as anonymous classes)
that implement EventListener type interfaces (ActionListener,
MouseListener, WindowListener, etc..).
Software Engineer
Instituto Tecnológico de Sonora
Sonora, México
@javierhumaran

Mais conteúdo relacionado

Mais procurados

Mais procurados (20)

MVC architecture
MVC architectureMVC architecture
MVC architecture
 
Model view controller (mvc)
Model view controller (mvc)Model view controller (mvc)
Model view controller (mvc)
 
JDBC
JDBCJDBC
JDBC
 
Angularjs PPT
Angularjs PPTAngularjs PPT
Angularjs PPT
 
Web api
Web apiWeb api
Web api
 
Asp.net.
Asp.net.Asp.net.
Asp.net.
 
Spring MVC Framework
Spring MVC FrameworkSpring MVC Framework
Spring MVC Framework
 
Webservices
WebservicesWebservices
Webservices
 
REST & RESTful Web Services
REST & RESTful Web ServicesREST & RESTful Web Services
REST & RESTful Web Services
 
Laravel overview
Laravel overviewLaravel overview
Laravel overview
 
ASP.NET - Life cycle of asp
ASP.NET - Life cycle of aspASP.NET - Life cycle of asp
ASP.NET - Life cycle of asp
 
Servlet life cycle
Servlet life cycleServlet life cycle
Servlet life cycle
 
Introduction to APIs (Application Programming Interface)
Introduction to APIs (Application Programming Interface) Introduction to APIs (Application Programming Interface)
Introduction to APIs (Application Programming Interface)
 
Introduction to spring boot
Introduction to spring bootIntroduction to spring boot
Introduction to spring boot
 
Spring Boot
Spring BootSpring Boot
Spring Boot
 
ASP.NET Page Life Cycle
ASP.NET Page Life CycleASP.NET Page Life Cycle
ASP.NET Page Life Cycle
 
ASP.NET MVC.
ASP.NET MVC.ASP.NET MVC.
ASP.NET MVC.
 
Introduction to mvc architecture
Introduction to mvc architectureIntroduction to mvc architecture
Introduction to mvc architecture
 
Introduction to Angularjs
Introduction to AngularjsIntroduction to Angularjs
Introduction to Angularjs
 
Servlet and servlet life cycle
Servlet and servlet life cycleServlet and servlet life cycle
Servlet and servlet life cycle
 

Semelhante a Model View Controller (MVC)

Architectural Design & Patterns
Architectural Design&PatternsArchitectural Design&Patterns
Architectural Design & PatternsInocentshuja Ahmad
 
Mvc 130330091359-phpapp01
Mvc 130330091359-phpapp01Mvc 130330091359-phpapp01
Mvc 130330091359-phpapp01Jennie Gajjar
 
Mvc pattern and implementation in java fair
Mvc   pattern   and implementation   in   java fairMvc   pattern   and implementation   in   java fair
Mvc pattern and implementation in java fairTech_MX
 
Ppt of Basic MVC Structure
Ppt of Basic MVC StructurePpt of Basic MVC Structure
Ppt of Basic MVC StructureDipika Wadhvani
 
Model View Controller ext4
Model View Controller  ext4Model View Controller  ext4
Model View Controller ext4Pankaj Avhad
 
Interaction-Oriented Architecture.pptx
Interaction-Oriented Architecture.pptxInteraction-Oriented Architecture.pptx
Interaction-Oriented Architecture.pptxGodwin Monserate
 
Cs 1023 lec 2 (week 1) edit 1
Cs 1023  lec 2 (week 1) edit 1Cs 1023  lec 2 (week 1) edit 1
Cs 1023 lec 2 (week 1) edit 1stanbridge
 
Cs 1023 lec 2 (week 1) edit 1
Cs 1023  lec 2 (week 1) edit 1Cs 1023  lec 2 (week 1) edit 1
Cs 1023 lec 2 (week 1) edit 1stanbridge
 
Web engineering - MVC
Web engineering - MVCWeb engineering - MVC
Web engineering - MVCNosheen Qamar
 
Software Design Patterns
Software Design PatternsSoftware Design Patterns
Software Design Patternsalkuzaee
 
What Are The Benefits Of Using MVC Framework In ASP.NET Development.pptx
What Are The Benefits Of Using MVC Framework In ASP.NET Development.pptxWhat Are The Benefits Of Using MVC Framework In ASP.NET Development.pptx
What Are The Benefits Of Using MVC Framework In ASP.NET Development.pptxQuickwayInfoSystems3
 
What Are The Benefits Of Using MVC Framework In ASP.NET Development.pptx
What Are The Benefits Of Using MVC Framework In ASP.NET Development.pptxWhat Are The Benefits Of Using MVC Framework In ASP.NET Development.pptx
What Are The Benefits Of Using MVC Framework In ASP.NET Development.pptxQuickwayInfoSystems3
 
MVC Seminar Presantation
MVC Seminar PresantationMVC Seminar Presantation
MVC Seminar PresantationAbhishek Yadav
 
IRJET- MVC Framework: A Modern Web Application Development Approach and Working
IRJET- MVC Framework: A Modern Web Application Development Approach and WorkingIRJET- MVC Framework: A Modern Web Application Development Approach and Working
IRJET- MVC Framework: A Modern Web Application Development Approach and WorkingIRJET Journal
 

Semelhante a Model View Controller (MVC) (20)

Architectural Design & Patterns
Architectural Design&PatternsArchitectural Design&Patterns
Architectural Design & Patterns
 
Mvc 130330091359-phpapp01
Mvc 130330091359-phpapp01Mvc 130330091359-phpapp01
Mvc 130330091359-phpapp01
 
Mvc pattern and implementation in java fair
Mvc   pattern   and implementation   in   java fairMvc   pattern   and implementation   in   java fair
Mvc pattern and implementation in java fair
 
Ppt of Basic MVC Structure
Ppt of Basic MVC StructurePpt of Basic MVC Structure
Ppt of Basic MVC Structure
 
Model View Controller ext4
Model View Controller  ext4Model View Controller  ext4
Model View Controller ext4
 
MVC - In Details
MVC - In DetailsMVC - In Details
MVC - In Details
 
MVC
MVCMVC
MVC
 
MVC
MVCMVC
MVC
 
Interaction-Oriented Architecture.pptx
Interaction-Oriented Architecture.pptxInteraction-Oriented Architecture.pptx
Interaction-Oriented Architecture.pptx
 
Cs 1023 lec 2 (week 1) edit 1
Cs 1023  lec 2 (week 1) edit 1Cs 1023  lec 2 (week 1) edit 1
Cs 1023 lec 2 (week 1) edit 1
 
Cs 1023 lec 2 (week 1) edit 1
Cs 1023  lec 2 (week 1) edit 1Cs 1023  lec 2 (week 1) edit 1
Cs 1023 lec 2 (week 1) edit 1
 
Web engineering - MVC
Web engineering - MVCWeb engineering - MVC
Web engineering - MVC
 
Software Design Patterns
Software Design PatternsSoftware Design Patterns
Software Design Patterns
 
What Are The Benefits Of Using MVC Framework In ASP.NET Development.pptx
What Are The Benefits Of Using MVC Framework In ASP.NET Development.pptxWhat Are The Benefits Of Using MVC Framework In ASP.NET Development.pptx
What Are The Benefits Of Using MVC Framework In ASP.NET Development.pptx
 
What Are The Benefits Of Using MVC Framework In ASP.NET Development.pptx
What Are The Benefits Of Using MVC Framework In ASP.NET Development.pptxWhat Are The Benefits Of Using MVC Framework In ASP.NET Development.pptx
What Are The Benefits Of Using MVC Framework In ASP.NET Development.pptx
 
MVC Seminar Presantation
MVC Seminar PresantationMVC Seminar Presantation
MVC Seminar Presantation
 
Asp.net,mvc
Asp.net,mvcAsp.net,mvc
Asp.net,mvc
 
Lec 4.ppt
Lec 4.pptLec 4.ppt
Lec 4.ppt
 
IRJET- MVC Framework: A Modern Web Application Development Approach and Working
IRJET- MVC Framework: A Modern Web Application Development Approach and WorkingIRJET- MVC Framework: A Modern Web Application Development Approach and Working
IRJET- MVC Framework: A Modern Web Application Development Approach and Working
 
Design pattern
Design patternDesign pattern
Design pattern
 

Mais de Javier Antonio Humarán Peñuñuri (10)

HTML5 Media Elements
HTML5 Media ElementsHTML5 Media Elements
HTML5 Media Elements
 
Buenas Prácticas para el uso de una Base de Datos
Buenas Prácticas para el uso de una Base de DatosBuenas Prácticas para el uso de una Base de Datos
Buenas Prácticas para el uso de una Base de Datos
 
XML, Webservice e RSS
XML, Webservice e RSSXML, Webservice e RSS
XML, Webservice e RSS
 
Segurança Em Computaçao Na Nuvem
Segurança Em Computaçao Na NuvemSegurança Em Computaçao Na Nuvem
Segurança Em Computaçao Na Nuvem
 
Java Server Pages
Java Server PagesJava Server Pages
Java Server Pages
 
Cuantificación de las necesidades de un producto o servicio
Cuantificación de las necesidades de un producto o servicioCuantificación de las necesidades de un producto o servicio
Cuantificación de las necesidades de un producto o servicio
 
Bici Tour, Proyecto de Desarrollo Emprendedor
Bici Tour, Proyecto de Desarrollo EmprendedorBici Tour, Proyecto de Desarrollo Emprendedor
Bici Tour, Proyecto de Desarrollo Emprendedor
 
Proceso de RUP
Proceso de RUPProceso de RUP
Proceso de RUP
 
Plan de Costos
Plan de CostosPlan de Costos
Plan de Costos
 
CPM, PERT Y GANTT
CPM, PERT Y GANTTCPM, PERT Y GANTT
CPM, PERT Y GANTT
 

Último

DSPy a system for AI to Write Prompts and Do Fine Tuning
DSPy a system for AI to Write Prompts and Do Fine TuningDSPy a system for AI to Write Prompts and Do Fine Tuning
DSPy a system for AI to Write Prompts and Do Fine TuningLars Bell
 
Passkey Providers and Enabling Portability: FIDO Paris Seminar.pptx
Passkey Providers and Enabling Portability: FIDO Paris Seminar.pptxPasskey Providers and Enabling Portability: FIDO Paris Seminar.pptx
Passkey Providers and Enabling Portability: FIDO Paris Seminar.pptxLoriGlavin3
 
Advanced Computer Architecture – An Introduction
Advanced Computer Architecture – An IntroductionAdvanced Computer Architecture – An Introduction
Advanced Computer Architecture – An IntroductionDilum Bandara
 
Merck Moving Beyond Passwords: FIDO Paris Seminar.pptx
Merck Moving Beyond Passwords: FIDO Paris Seminar.pptxMerck Moving Beyond Passwords: FIDO Paris Seminar.pptx
Merck Moving Beyond Passwords: FIDO Paris Seminar.pptxLoriGlavin3
 
Transcript: New from BookNet Canada for 2024: Loan Stars - Tech Forum 2024
Transcript: New from BookNet Canada for 2024: Loan Stars - Tech Forum 2024Transcript: New from BookNet Canada for 2024: Loan Stars - Tech Forum 2024
Transcript: New from BookNet Canada for 2024: Loan Stars - Tech Forum 2024BookNet Canada
 
Gen AI in Business - Global Trends Report 2024.pdf
Gen AI in Business - Global Trends Report 2024.pdfGen AI in Business - Global Trends Report 2024.pdf
Gen AI in Business - Global Trends Report 2024.pdfAddepto
 
The Role of FIDO in a Cyber Secure Netherlands: FIDO Paris Seminar.pptx
The Role of FIDO in a Cyber Secure Netherlands: FIDO Paris Seminar.pptxThe Role of FIDO in a Cyber Secure Netherlands: FIDO Paris Seminar.pptx
The Role of FIDO in a Cyber Secure Netherlands: FIDO Paris Seminar.pptxLoriGlavin3
 
Anypoint Exchange: It’s Not Just a Repo!
Anypoint Exchange: It’s Not Just a Repo!Anypoint Exchange: It’s Not Just a Repo!
Anypoint Exchange: It’s Not Just a Repo!Manik S Magar
 
The State of Passkeys with FIDO Alliance.pptx
The State of Passkeys with FIDO Alliance.pptxThe State of Passkeys with FIDO Alliance.pptx
The State of Passkeys with FIDO Alliance.pptxLoriGlavin3
 
unit 4 immunoblotting technique complete.pptx
unit 4 immunoblotting technique complete.pptxunit 4 immunoblotting technique complete.pptx
unit 4 immunoblotting technique complete.pptxBkGupta21
 
From Family Reminiscence to Scholarly Archive .
From Family Reminiscence to Scholarly Archive .From Family Reminiscence to Scholarly Archive .
From Family Reminiscence to Scholarly Archive .Alan Dix
 
DevEX - reference for building teams, processes, and platforms
DevEX - reference for building teams, processes, and platformsDevEX - reference for building teams, processes, and platforms
DevEX - reference for building teams, processes, and platformsSergiu Bodiu
 
Artificial intelligence in cctv survelliance.pptx
Artificial intelligence in cctv survelliance.pptxArtificial intelligence in cctv survelliance.pptx
Artificial intelligence in cctv survelliance.pptxhariprasad279825
 
Time Series Foundation Models - current state and future directions
Time Series Foundation Models - current state and future directionsTime Series Foundation Models - current state and future directions
Time Series Foundation Models - current state and future directionsNathaniel Shimoni
 
Developer Data Modeling Mistakes: From Postgres to NoSQL
Developer Data Modeling Mistakes: From Postgres to NoSQLDeveloper Data Modeling Mistakes: From Postgres to NoSQL
Developer Data Modeling Mistakes: From Postgres to NoSQLScyllaDB
 
Unraveling Multimodality with Large Language Models.pdf
Unraveling Multimodality with Large Language Models.pdfUnraveling Multimodality with Large Language Models.pdf
Unraveling Multimodality with Large Language Models.pdfAlex Barbosa Coqueiro
 
"Subclassing and Composition – A Pythonic Tour of Trade-Offs", Hynek Schlawack
"Subclassing and Composition – A Pythonic Tour of Trade-Offs", Hynek Schlawack"Subclassing and Composition – A Pythonic Tour of Trade-Offs", Hynek Schlawack
"Subclassing and Composition – A Pythonic Tour of Trade-Offs", Hynek SchlawackFwdays
 
DevoxxFR 2024 Reproducible Builds with Apache Maven
DevoxxFR 2024 Reproducible Builds with Apache MavenDevoxxFR 2024 Reproducible Builds with Apache Maven
DevoxxFR 2024 Reproducible Builds with Apache MavenHervé Boutemy
 
"Debugging python applications inside k8s environment", Andrii Soldatenko
"Debugging python applications inside k8s environment", Andrii Soldatenko"Debugging python applications inside k8s environment", Andrii Soldatenko
"Debugging python applications inside k8s environment", Andrii SoldatenkoFwdays
 
Nell’iperspazio con Rocket: il Framework Web di Rust!
Nell’iperspazio con Rocket: il Framework Web di Rust!Nell’iperspazio con Rocket: il Framework Web di Rust!
Nell’iperspazio con Rocket: il Framework Web di Rust!Commit University
 

Último (20)

DSPy a system for AI to Write Prompts and Do Fine Tuning
DSPy a system for AI to Write Prompts and Do Fine TuningDSPy a system for AI to Write Prompts and Do Fine Tuning
DSPy a system for AI to Write Prompts and Do Fine Tuning
 
Passkey Providers and Enabling Portability: FIDO Paris Seminar.pptx
Passkey Providers and Enabling Portability: FIDO Paris Seminar.pptxPasskey Providers and Enabling Portability: FIDO Paris Seminar.pptx
Passkey Providers and Enabling Portability: FIDO Paris Seminar.pptx
 
Advanced Computer Architecture – An Introduction
Advanced Computer Architecture – An IntroductionAdvanced Computer Architecture – An Introduction
Advanced Computer Architecture – An Introduction
 
Merck Moving Beyond Passwords: FIDO Paris Seminar.pptx
Merck Moving Beyond Passwords: FIDO Paris Seminar.pptxMerck Moving Beyond Passwords: FIDO Paris Seminar.pptx
Merck Moving Beyond Passwords: FIDO Paris Seminar.pptx
 
Transcript: New from BookNet Canada for 2024: Loan Stars - Tech Forum 2024
Transcript: New from BookNet Canada for 2024: Loan Stars - Tech Forum 2024Transcript: New from BookNet Canada for 2024: Loan Stars - Tech Forum 2024
Transcript: New from BookNet Canada for 2024: Loan Stars - Tech Forum 2024
 
Gen AI in Business - Global Trends Report 2024.pdf
Gen AI in Business - Global Trends Report 2024.pdfGen AI in Business - Global Trends Report 2024.pdf
Gen AI in Business - Global Trends Report 2024.pdf
 
The Role of FIDO in a Cyber Secure Netherlands: FIDO Paris Seminar.pptx
The Role of FIDO in a Cyber Secure Netherlands: FIDO Paris Seminar.pptxThe Role of FIDO in a Cyber Secure Netherlands: FIDO Paris Seminar.pptx
The Role of FIDO in a Cyber Secure Netherlands: FIDO Paris Seminar.pptx
 
Anypoint Exchange: It’s Not Just a Repo!
Anypoint Exchange: It’s Not Just a Repo!Anypoint Exchange: It’s Not Just a Repo!
Anypoint Exchange: It’s Not Just a Repo!
 
The State of Passkeys with FIDO Alliance.pptx
The State of Passkeys with FIDO Alliance.pptxThe State of Passkeys with FIDO Alliance.pptx
The State of Passkeys with FIDO Alliance.pptx
 
unit 4 immunoblotting technique complete.pptx
unit 4 immunoblotting technique complete.pptxunit 4 immunoblotting technique complete.pptx
unit 4 immunoblotting technique complete.pptx
 
From Family Reminiscence to Scholarly Archive .
From Family Reminiscence to Scholarly Archive .From Family Reminiscence to Scholarly Archive .
From Family Reminiscence to Scholarly Archive .
 
DevEX - reference for building teams, processes, and platforms
DevEX - reference for building teams, processes, and platformsDevEX - reference for building teams, processes, and platforms
DevEX - reference for building teams, processes, and platforms
 
Artificial intelligence in cctv survelliance.pptx
Artificial intelligence in cctv survelliance.pptxArtificial intelligence in cctv survelliance.pptx
Artificial intelligence in cctv survelliance.pptx
 
Time Series Foundation Models - current state and future directions
Time Series Foundation Models - current state and future directionsTime Series Foundation Models - current state and future directions
Time Series Foundation Models - current state and future directions
 
Developer Data Modeling Mistakes: From Postgres to NoSQL
Developer Data Modeling Mistakes: From Postgres to NoSQLDeveloper Data Modeling Mistakes: From Postgres to NoSQL
Developer Data Modeling Mistakes: From Postgres to NoSQL
 
Unraveling Multimodality with Large Language Models.pdf
Unraveling Multimodality with Large Language Models.pdfUnraveling Multimodality with Large Language Models.pdf
Unraveling Multimodality with Large Language Models.pdf
 
"Subclassing and Composition – A Pythonic Tour of Trade-Offs", Hynek Schlawack
"Subclassing and Composition – A Pythonic Tour of Trade-Offs", Hynek Schlawack"Subclassing and Composition – A Pythonic Tour of Trade-Offs", Hynek Schlawack
"Subclassing and Composition – A Pythonic Tour of Trade-Offs", Hynek Schlawack
 
DevoxxFR 2024 Reproducible Builds with Apache Maven
DevoxxFR 2024 Reproducible Builds with Apache MavenDevoxxFR 2024 Reproducible Builds with Apache Maven
DevoxxFR 2024 Reproducible Builds with Apache Maven
 
"Debugging python applications inside k8s environment", Andrii Soldatenko
"Debugging python applications inside k8s environment", Andrii Soldatenko"Debugging python applications inside k8s environment", Andrii Soldatenko
"Debugging python applications inside k8s environment", Andrii Soldatenko
 
Nell’iperspazio con Rocket: il Framework Web di Rust!
Nell’iperspazio con Rocket: il Framework Web di Rust!Nell’iperspazio con Rocket: il Framework Web di Rust!
Nell’iperspazio con Rocket: il Framework Web di Rust!
 

Model View Controller (MVC)

  • 1.
  • 2. • Software architecture pattern that separates the model, the user interface and control logic of an application in three distinct components.
  • 3. • MVC proposes the construction of three distinct components. One side for the representation of information, and on the other hand for user interaction. One model Many Views Many Controllers
  • 4. The Model Representation of domain data. Business logic Persistence mechanism The View User Interface Interaction elements The Controller Intermediary between Model and View It maps user actions – model actions Select the view and provide information to itself
  • 5. It is the specific representation of the information with which the system operates. Logic ensures the integrity of data and allows to derive it.
  • 6. Represents the model in a suitable format to interact and access the data, usually called "User Interface" (GUI Java, HTML, XML).
  • 7. It is the link between the view and the model, is responsible for receiving and responding to events, typically user actions and invokes changes on the model and probably in the view.
  • 8. • Organization • Rapid Application Development • Reusing Code • Parallel development • It presents the same information in different ways. • The views and application behavior should reflect the manipulations of the data immediately. • It allows different user interface standards or port it to other environments where the application code should not be affected.
  • 9. • This model is not new, it was introduced in 1987 in the Smalltalk programming language. • With the boom of Web applications, it has proven to be a programming mode that fits quite well with the internet, being both the model and the controller executed server side, and the view on the client side executed.
  • 10. Control Flow 1. 2. 3. 4. 5. The user performs an action on the interface. The controller takes the input event. The controller notifies the user action to the model, which may involve a change of state of the model. It generates a new view. The view takes the data model. The user interface waits for another user interaction, which starts a new cycle.
  • 11. Controller updates the model View alerts controller of a particular event View grabs model data and updates itself User interacts with a view Model alerts view that it has changed
  • 12. • It applies to all types of systems • And technologies (Java, Ruby, Python, Perl, Flex, SmallTalk,. Net, etc..)
  • 13. • Model: The model is made by the developer. • View: Set of objects of classes that inherit from java.awt.Component. • Controller: The controller is the event processing thread, which captures and propagates the event to the view and the model. Treatment classes of events (sometimes as anonymous classes) that implement EventListener type interfaces (ActionListener, MouseListener, WindowListener, etc..).
  • 14. Software Engineer Instituto Tecnológico de Sonora Sonora, México @javierhumaran