Skip to content

A simple solution which demonstrates a good (flexible) architecture for WPF applications, applying MVVM, Services, ServiceLocator.

License

Notifications You must be signed in to change notification settings

quicoli/WPFArquitectureDemo

Repository files navigation

A Simple WPF Architecture Demo

Some years ago I wrote an article for DevMedia group named "Comandments of Object Orientation", based in what I'd worked, learned, read, and studied. So I can say:

The goal of this project is to show how build a good (flexible) solution for WPF applications.

Well, this is not a silver bullet, but it's a starting point and I'd like to let an open discussion here.

What you can see

  • How to keep logic in ViewModel, avoiding code-behind
  • Use commands to abstract user actions
  • Dispatch specific messages (message mediator pattern) to accomplish specific actions
  • UI message services
  • Program to interface, not implementation
  • Model validation
  • NHibernate (in a simple way)
  • Mapping Models->Entities and Entities<-Models

In the next days I'm creating some wikis explaining the code

What is inside

This is an one Window only application using the following packages:

All packages available by nuget, except MVVMHelper (binaries included)

##Instructions

As SQLite database is not created, open App.xml.cs and change this line:

SessionFactory = Bootstrapper.Initialize(false);

to

SessionFactory = Bootstrapper.Initialize(true);

and run the application, so database will be created.

After first run you can change back to

SessionFactory = Bootstrapper.Initialize(false);

About

A simple solution which demonstrates a good (flexible) architecture for WPF applications, applying MVVM, Services, ServiceLocator.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages