codewiz
Check me out on the web at patterns and practices Developer Center Home or at my blog.
Glenn Block is the Technical Product Planner for the Client UX program at patterns & practices. As Product Planner he is responsible for driving the vision and creation of p&p client deliverables including the Web Client and Smart Client software factories. Prior to joining Microsoft, Glenn has lived in various roles being "in the trenches" with developers, including being responsible for the overall architecture and technology direction. He has worked in both large and small organizations build...
10-4 Episode 32: MEF Preview 7
Oct 20, 2009 at 11:50 AMBrandon
Good question and timing. Yes, I am planning to put one in contrib. Here's the code if you want it now
http://codepaste.net/s6w6az
If you look in the sample you will notice a Unity extension as well. The reason is that to use this EP, something has to tell it the available registered types so that it can map them to contract names, as MEF is solely contract based. You'll see the extension invokes a method on the EP.
10-4 Episode 32: MEF Preview 7
Sep 11, 2009 at 2:40 AMCool, good luck. Let us know how it works out, and blog blog blog
10-4 Episode 32: MEF Preview 7
Sep 11, 2009 at 2:40 AMThanks Tomasz. I am surprised you want to see any more of my code after the hours upon hours that you saw in Poland
10-4 Episode 32: MEF Preview 7
Sep 11, 2009 at 2:39 AMHi Bondsbw
We have supported this for quite a while now. Our container accepts custom ExportProviders which can talk to another source for exports including an IoC container. There's an example out there in the community now that leverages this for integration with Unity. You can find it at mefcontrb.codeplex.com.
You are correct in your understanding. With an EP, you can have MEF parts with Imports that will be provided by an IoC container. We'll be doing a blog post on this at some point. But this post covers the fundamentals: http://codebetter.com/blogs/glenn.block/archive/2008/12/25/using-exportprovider-to-customize-container-behavior-part-i.aspx
Thanks
Glenn
10-4 Episode 32: MEF Preview 7
Sep 11, 2009 at 2:36 AMHi Al
We definitely plan on rolling the new features into the full framework. It's too late in the cycle to do that for .NET 4.0, if we could we definitely would.
Silverlight ships on a different schedule, which opened up the opportunity to add new features like we are doing. For the desktop, we plan to make 3.5/4.0 versions of those features available on Codeplex in the interim.
Thanks
Glenn
Client-side Model-View-Presenter
Sep 29, 2007 at 11:50 AM