MVC vs MVP. MVC, as I said in a earlier post is Model View Controller. The controller is used primarily for the interactions from the model to the view/user. It (the controller) is responsible for getting the correct view out to the user.
Lets explore MVP a touch and then we will go into the differences. MVP, Model, View, Presenter. Model, just like MVC, is what holds the data, no manipulation occurs at this level. View, the user interface, but as Mike Potel from Taligent (IBM) says separates this view from the MVC view is that nearly all common day operating systems and software languages provide most of the controller functionality and the ‘controller” idea is now unnecessary for the most part. Lastly, the presenter, the data and view intermediary. The presenter is more like a stepping stone for the view and the model, it’s job is to serve the view with the model so it can bind to the data.
The main differences here are relatively clear; the view in MVP has business logic and will delegate to the presenter. It (the MVP view) also has data bindings to the model. The MVC design pattern uses the controller to server the views and does not allow direct access to the model for the view.
Summation: MVP seems to be a more natural method of how programming is going, even if people continue to use the MVC acronym when they mean MVP. In my opinion, after this research, I believe many people are just oblivious to this separation. I can see that in a more responsive design with a heavy ajax view that the MVP pattern would be much more useful than going clear cut MVC.
Thanks again for reading,
~(ME)
Happy Birthday Meyer