Successfully reported this slideshow.
We use your LinkedIn profile and activity data to personalize ads and to show you more relevant ads. You can change your ad preferences anytime.
David Giard<br />MCTS, MCSD, MCSE, MCDBA<br />Principal Consultant, Sogeti<br />www.DavidGiard.com<br />DavidGiard@DavidGi...
Managed Extensibility Framework<br />Beta 2<br />
Compile and Deploy<br />Tight Coupling<br />DLL<br />DLL<br />EXE<br />
MEF<br />Loose Coupling with mef<br />Compile and Deploy<br />DLL<br />DLL<br />EXE<br />DLL<br />Contract<br />Contract<b...
Managed Extensibility Framework<br />Applications consists of loosely-coupled components that are discovered and composed ...
Advantages of mef<br />Loose Coupling<br />Swap Classes at Runtime<br />No Recompile or Redeploy<br />Single Plug-In Archi...
MEF Usage Scenarios<br />Empower developers to extend your application without modifying it<br />Provide extra modules to ...
Demo<br />G/L<br />Modules for Accounting app<br />A/R<br />MEFApp<br />(Accounting)<br />GenSetup<br />A/P<br />Export<br />
Existing Extensibility in .Net<br />Visual Studio Add-Ins<br />Microsoft Tools for Office<br />Rules Engines<br />WCF<br /...
Get Started<br />MEF.CodePlex.com  <br />Download and unzip MEF_Beta_2.zip<br />Zip file contains<br />DLLs<br />Samples<b...
Developer Steps<br />Set Reference to System.ComponentModel.Composition.dll<br />Contract<br />Import<br />Export<br />Cat...
MEF<br />Contracts<br />[Import(“Contract1”)]<br />String  SomeThing {get; set;}<br />[Export(“Contract1”)]<br />Public st...
MEF<br />Contracts<br />[Import(“Contract1”)]<br />String  SomeThing {get; set;}<br />[Export(“Contract1”)]<br />Public st...
MEF<br />Interface Contracts<br />[Import(typeof(IFoo))]<br />IFooSomeFoo {get; set;}<br />[Export(typeof(IFoo))]<br />pub...
MEF<br />Interface Contracts<br />[Export(typeof(IFoo))]<br />public Foo1: IFoo{<br />…<br />}<br />[ImportMany(typeof(IFo...
Composition<br />varcatalog1     = newDirectoryCatalog(@&quot;c:MEFImports&quot;);<br />var container = newCompositionCont...
Demo<br />Using MEF<br />
MEF vs  Dependency Injection<br />
rESOURCES<br />http://MEF.codeplex.com<br />http://www.davidgiard.com<br />http://msmvps.com/blogs/kathleen<br />http://bl...
User Groups<br />Great Lakes Area .Net User Group<br />Southfield, MI<br />migang.org<br />Greater Lansing .Net User Group...
Dave’s Thoughts<br />DavidGiard.com<br />TechnologyAndFriends.com<br />DavidGiard@DavidGiard.com<br />
You’ve finished this document.
Download and read it offline.
Upcoming SlideShare
Criterios
Next
Upcoming SlideShare
Criterios
Next
Download to read offline and view in fullscreen.

Share

Managed Extensibility Framework 2010 01

Download to read offline

Related Books

Free with a 30 day trial from Scribd

See all

Managed Extensibility Framework 2010 01

  1. 1. David Giard<br />MCTS, MCSD, MCSE, MCDBA<br />Principal Consultant, Sogeti<br />www.DavidGiard.com<br />DavidGiard@DavidGiard.com<br />
  2. 2. Managed Extensibility Framework<br />Beta 2<br />
  3. 3. Compile and Deploy<br />Tight Coupling<br />DLL<br />DLL<br />EXE<br />
  4. 4. MEF<br />Loose Coupling with mef<br />Compile and Deploy<br />DLL<br />DLL<br />EXE<br />DLL<br />Contract<br />Contract<br />Contract<br />Contract<br />
  5. 5. Managed Extensibility Framework<br />Applications consists of loosely-coupled components that are discovered and composed at runtime<br />
  6. 6. Advantages of mef<br />Loose Coupling<br />Swap Classes at Runtime<br />No Recompile or Redeploy<br />Single Plug-In Architecture<br />
  7. 7. MEF Usage Scenarios<br />Empower developers to extend your application without modifying it<br />Provide extra modules to your application, as needed<br />Use MEF as an platform ecosystem to manage all parts of your application<br />
  8. 8. Demo<br />G/L<br />Modules for Accounting app<br />A/R<br />MEFApp<br />(Accounting)<br />GenSetup<br />A/P<br />Export<br />
  9. 9. Existing Extensibility in .Net<br />Visual Studio Add-Ins<br />Microsoft Tools for Office<br />Rules Engines<br />WCF<br />Interfaces<br />Reflection<br />IOC / Dependency Injection<br />
  10. 10. Get Started<br />MEF.CodePlex.com <br />Download and unzip MEF_Beta_2.zip<br />Zip file contains<br />DLLs<br />Samples<br />Source Code<br />
  11. 11. Developer Steps<br />Set Reference to System.ComponentModel.Composition.dll<br />Contract<br />Import<br />Export<br />Catalogs<br />Composition<br />Import<br />Contracts<br />Export<br />
  12. 12. MEF<br />Contracts<br />[Import(“Contract1”)]<br />String SomeThing {get; set;}<br />[Export(“Contract1”)]<br />Public string SpecialThing{<br />Get {return “A Value”};<br />}<br />“A Value”<br />
  13. 13. MEF<br />Contracts<br />[Import(“Contract1”)]<br />String SomeThing {get; set;}<br />[Export(“Contract1”)]<br />Public string MoreSpecialThing{<br />Get {return “A Different Value”};<br />}<br />“A Different Value”<br />
  14. 14. MEF<br />Interface Contracts<br />[Import(typeof(IFoo))]<br />IFooSomeFoo {get; set;}<br />[Export(typeof(IFoo))]<br />public Foo: IFoo{<br />…<br />}<br />new Foo()<br />
  15. 15. MEF<br />Interface Contracts<br />[Export(typeof(IFoo))]<br />public Foo1: IFoo{<br />…<br />}<br />[ImportMany(typeof(IFoo))]<br />List&lt;IFoo&gt; BunchOfFoos{get; set;}<br />new Foo1()<br />[Export(typeof(IFoo))]<br />public Foo2: IFoo{<br />…<br />}<br />new Foo2()<br />
  16. 16. Composition<br />varcatalog1 = newDirectoryCatalog(@&quot;c:MEFImports&quot;);<br />var container = newCompositionContainer<br />catalog1);<br />container.ComposeParts(this);<br />Catalogs<br />TypeCatalog<br />AssemblyCatalog<br />DirectoryCatalog<br />AggregateCatalog<br />PackageCatalog (Silverlight toolkit)<br />
  17. 17. Demo<br />Using MEF<br />
  18. 18. MEF vs Dependency Injection<br />
  19. 19. rESOURCES<br />http://MEF.codeplex.com<br />http://www.davidgiard.com<br />http://msmvps.com/blogs/kathleen<br />http://blogs.msdn.com/gblock<br />http://tinyurl.com/TaultyMEFSilverlightVideos<br />NPlus1.org<br />David Giard, MCTS, MCSD, MCSE, MCDBA<br />www.DavidGiard.com<br />DavidGiard@DavidGiard.com<br />
  20. 20. User Groups<br />Great Lakes Area .Net User Group<br />Southfield, MI<br />migang.org<br />Greater Lansing .Net User Group<br />East Lansing, MI<br />glugnet.org<br />
  21. 21. Dave’s Thoughts<br />DavidGiard.com<br />TechnologyAndFriends.com<br />DavidGiard@DavidGiard.com<br />
  • nkaluva

    Oct. 15, 2013
  • dhavalcharadva

    Sep. 19, 2013

Views

Total views

2,940

On Slideshare

0

From embeds

0

Number of embeds

521

Actions

Downloads

29

Shares

0

Comments

0

Likes

2

×