Introduction
The MVVM pattern includes the following:
- Model. The model represents the
underlying, logical structure of data in a software application and the
high-level classes associated with it. This object model does not typically
contain any information about the user interface.
- View. A View is typically some
form of user interface element that lets users interact with the
application. In a Windows Presentation Foundation (WPF) or Silverlight
application, typically each view is composed of an Extensible Application
Markup Language (XAML) file and its corresponding code behind.
- ViewModel. The view model is an
intermediate class between the view and the model. It references the model
and calls methods on the model to retrieve domain objects, which are
typically exposed to the view as a flat set of properties. The communication
between view and view model should be purely through data binding.