During one of the discussion internally with practice team members, we talked about few differences between Model View Controller (MVC), Model View Presenter (MVP) and Model View ViewModel (MVVM) patterns. Breifly looked at the web and I could consolidate the final understandings as below :
MVP
- Presenter contains the business logic for View
- Presenter binds data to model
- Presenter is exposed through interface
- View is called directly
- View does not bind directly to the model it mediates through presenter
- This is achievable in ASP.Net web applications
MVC
- Controller determines which view to display
- View is bound to a model
- View is stateless and no code behind required
- This is the pattern used in ASP.Net MVC
MVVM
- View Model is also called presentation model which acts as intermediate for View to talk to.
- View Model will talk to the underlying domain model (like Entity Framework)
- Mostly used in Silverlight and WPF where the control binding to data happens through the presentation model and does not need to have properties in the view and have UI business logic to it.
There are hell lot of blogs and articles about these to help you more but what I thought is to put a simple note about all.
Any change in your view about this blog, please present it to me :).
References :
http://stackoverflow.com/questions/2056/what-are-mvp-and-mvc-and-what-is-the-difference
MVP
- Presenter contains the business logic for View
- Presenter binds data to model
- Presenter is exposed through interface
- View is called directly
- View does not bind directly to the model it mediates through presenter
- This is achievable in ASP.Net web applications
MVC
- Controller determines which view to display
- View is bound to a model
- View is stateless and no code behind required
- This is the pattern used in ASP.Net MVC
MVVM
- View Model is also called presentation model which acts as intermediate for View to talk to.
- View Model will talk to the underlying domain model (like Entity Framework)
- Mostly used in Silverlight and WPF where the control binding to data happens through the presentation model and does not need to have properties in the view and have UI business logic to it.
There are hell lot of blogs and articles about these to help you more but what I thought is to put a simple note about all.
Any change in your view about this blog, please present it to me :).
References :
http://stackoverflow.com/questions/2056/what-are-mvp-and-mvc-and-what-is-the-difference