开发者

Basic MEF workflow/usage

I'm looking to a framework which will allow me to have a simple plugin system in my .NET application. I开发者_高级运维t seems MEF is the framework which Microsoft is endorsing, and will become part of .NET 4 (it also seems to work with older .NET versions as a separate library, as well as Mono).

I'm previously used Mono.Addins as for a plugin system for a different project. The basic idea is I define a set of interfaces, these become "extension points", a plugin API if you will for the application.

Can MEF be used in a similar manner? How can I get started with MEF, especially from the perspective of someone with experience with Mono.Addins?


Yes, and I posted an example of how to do what you're talking about with MEF in a CodeProject article: Building an Extensible Application with MEF, WPF, and MVVM


Have you looked at the MEF CodePlex Site? The Programming Guide there is a pretty good place to get started.


Will an IOC utility work for your needs? I've found autofac really straight forward.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜