Model View Controller
is an implementation architecture often used for user-interfaces.
It allows for a separation between the implementation of the visible aspects
of a user-interface and the logic that governs its behaviour.
Unfortunately, the term MVC is used to mean quite different things by different
people. This document attempts to explain some of the architectures that are
described as being "MVC" and point out their differences.
MVC in Apple's Cocoa Framework
gives strong support for the use of MVC - in fact it is almost a requirement
for proper use of the Cocoa framework. As explained in
Apple's doc about Cocoa design patterns
objects encapsulate data and behaviour,
objects present information to the user and allow for
and the controller
objects intermediate between the model objects
and the view objects. The controller objects "know" about the model objects and
the view objects, but the model and view don't "know" about each other
- all data flow goes via the controller.
At Apple's developer conference "WWDC 2003",
James Dempsey sang a song about MVC