I am sitting here at the opening of ALT.NET Seattle. I look around and see the words "Learn, Share, Grow” on a poster, words I first wrote on the ALT.NET wiki about two months ago. At the time I when I wrote it,
The title probably sounds like an oxymoron, but it is not. Recently there was a question on our CodePlex forums from Denis Vuyka about whether or not MEF supports anything like EventBroker for pub/sub type communication. Asking such a question makes a lot of sense,
Today, I finally got around to uploading a CommonServiceLocator adapter for MEF.
The code is actually quite simple thanks to Chris Tavares providing ServiceLocatorImplBase. (Updated thanks to feedback from several folks)
public class MefServiceLocator : ServiceLocatorImplBase
private ExportProvider _provider;
public MefServiceLocator(ExportProvider provider)
_provider = provider;