Advertisement: Give and take for free. Reduce clutter from home. Reuse stuff and save money.
www.letsdonatestuff.com
Project DescriptionThis project contains a sample application demonstrating the Model View ViewModel Presenter (MVVMP) Pattern using Unity, MEF and Prism
It also contains a stub that can be used to rapidly build an MVVMP based application using Prism.
class LEDPresenter: PresenterBase<ILEDView, LEDViewModel>
{
public LEDPresenter(ILEDView view, IEventAggregator eventAggregator): base(view)
{
eventAggregator.GetEvent<ResultChangedEvent>().Subscribe(OnResultChanged);
}
void OnResultChanged(int result)
{
ViewModel.Result = result;
}
}
Read the following for explanation: