Discovering open source WPF components – Orc.ProjectManagement

In the discovering open source WPF components series, I will look into useful open source components that can be used to create WPF apps. This weeks component is Orc.ProjectManagement.

Ever needed to manage one (SDI) or multiple (MDI) projects in your application? At first you start with a model, very easy. Then people ask you if they can have multiple projects at the same time. Then they ask you have application-wide commands for the currently active project. And then you found out that all that you have written was already in Orc.ProjectManagement.

The project management library makes it easy to manage projects. The main component is the IProjectManager that contains the current project and allows to load or save a project. Note that this library does not force you to use a specific project location of any sort, so it can even be a database or server call to read / write the project. A few very handy events that every app needs are listed below:

  • ProjectLoading
  • ProjectLoaded
  • ProjectClosing
  • ProjectClosed
  • ProjectRefreshing
  • ProjectRefreshed
  • ProjectSaving
  • ProjectSaved
  • etc

Creating a project

The most important thing in project management is a project class that can be managed.

Creating a project reader

Creating a project writer

There is much more to discover

To prevent this blog post from getting too long, I will stop here. But there is much more to discover in this library:

  • IProjectValidator => validate if a project can be loaded (file exists, directory exists, can connect to db, etc)
  • IProjectInitializer => what should the IProjectManager do at startup? Load a file that was specified via command line arguments, open a directory, always start with an empty demo project, or anything you like