Thursday, July 23, 2015

MVC Vs MVP vs MVVM

MVC Vs MVP vs MVVM
MVP
  • Use in situations where binding via a datacontext is not possible.
  • Windows Forms is a perfect example of this.  In order to separate the view from the model, a presenter is needed.  Since the view cannot directly bind to the presenter, information must be passed to it view an interface (IView).
MVVM
  • Use in situations where binding via a datacontext is possible.  Why?  The various IView interfaces for each view are removed which means less code to maintain.
  • Some examples where MVVM is possible include WPF and javascript projects using Knockout.
MVC
  • Use in situations where the connection between the view and the rest of the program is not always available (and you can’t effectively employ MVVM or MVP).
  • This clearly d  Microsoft’s ASP.NET Mescribes the situation where a web API is separated from the data sent to the client browsers.VC is a great tool for managing such situations and provides a very clear MVC framework.

No comments:

Post a Comment