Search Wiki:

MEF is now on CodePlex along with full source.


You can get to it here http://www.codeplex.com/MEF. At the site you can start discussions as well as add new workitems, and vote on existing.

The Managed Extensibility Framework (MEF) is a new library in .NET that enables greater reuse of applications and components. Using MEF, .NET applications can make the shift from being statically compiled to dynamically composed. If you are building extensible applications, extensible frameworks and application extensions, then MEF is for you.
Last edited Nov 18 2008 at 3:04 PM  by gblock, version 12
Comments
Rajiv wrote  Jun 5 2008 at 7:49 AM  
Kudos

brettryan wrote  Jun 18 2008 at 9:05 AM  
This certainly looks interesting, I'm wondering how this relates to both P&P Composite WPF (formerly Prism) and the P&P Unity dependancy injection container. Are there distinct use cases for Composite WPF and MEF or are the two projects blurred in terms of goals?

mnmr wrote  Jun 24 2008 at 4:37 PM  
I'd like to second brettryan's comment.. where does this project fit in the broader landscape of existing DI/IoC frameworks?

gblock wrote  Jun 27 2008 at 11:36 PM  
@mnmr, @brettryan

MEF is focused on application extensibility. It uses DI as a strategy for composing the different extensions, however it is not in itself a generic DI container. Composite Application Guidance for WPF is a set of guidance for building Composite Applications in WPF. While it does have a module loading facility for extensibility, the type of extensibilty it offers is very specific for composite applications.

Conceptually MEF should be able to live side by side with the Composite Application Library (CAL) included with the guidance. p&p is going to explore how the two can work together. Would you imagine needing this? If so, why?

As far as the use cases, I would say.

1. If you are looking to build a composite application with WPF, use Composite WPF.
2. If you are looking to build an application with built in extensiblity points that can easily be discovered, and which supports discovery of extensions, then look to MEF

Thanks
Glenn


gmelnik wrote  Jul 5 2008 at 5:05 AM  
...and 3. If you are building a loosely-coupled application and looking for looking for a generic DI container to delegate the responsibility of creating/resolving the objects as needed, use Unity (http://msdn.microsoft.com/unity).

wmpjohnston wrote  Jul 21 2008 at 3:28 AM  
@Glenn
I'd really like to see some guidance from P&P on building WPF apps with MEF. Is this on P&P's radar? My understanding is that MEF streamlines add-in management and DI for Windows apps? BTW, congrats on the new job.

redhotsly wrote  Dec 15 2008 at 7:08 PM  
> however it is not in itself a generic DI container.

Hi, Can you explain why MEF should not be used also as a generic DI container?

joewood72 wrote  Mar 11 2009 at 2:21 PM  
I would like to echo that question. Given that MEF will be in .NET 4 will a future version of Unity be built ontop of the MEF attributes?
I consider an extension framework to 'unknown components' to be a superset of an composite framework for 'known components'.
Will PRISM have a MEF bootstrapper?

roop452 wrote  Feb 25 2010 at 4:38 AM  
Mehfuz Hossain and Sachin Vinod Rathi is coming this April to India's 3rd Edition of Great Indian Developer Summit (developersummit dot com) to speak about putting the 2010 version of Visual Studio to use, which will be held on 20th April in IIsc, Bangalore

Ajay555 wrote  Apr 10 2010 at 11:34 AM  
One of the comment posted in my earlier example of MEF was what if we have two implementations of the same interface and we need to decide at run time which implementation to use. I have posted another blog which gives the example of usage of ExportMetadata for handing this scenario.

http://ppsinfo.blogspot.com/2010/04/managed-extensibility-framework-mef.html

Ajay555 wrote  Jun 2 2010 at 6:38 PM  
I got some comments to post the MEF Example II source code in VS 2010 and .NET 4.0. Well I am happy to say that its now available for download.

http://ajay555.wordpress.com/2010/06/03/mef-example-part-ii-vs2010-and-net-4-0/

bernardsofateam wrote  Mar 6 2011 at 9:48 AM  
Sofa is a library allowing easy creation of docking applications. In order to make components working together we embedded MEF.
It works fine and we need comments and advices to improve it. Don't hesitate to have a look at http://sofawpf.codeplex.com/wikipage?title=Sofa%20and%20MEF&referringTitle=Documentation !

Updating...
Page view tracker