Hi all, I'm writing a plugin system: every plugin is in his own assembly that must be loaded by autofac and is signed by an attribute with a parameter that set the type of plugin. I would be able to resolve in my asp.net mvc app the plugins by type, how can I do this? Every plugin inhrerit by an abstract class and override predefinited methods.
why would you use mef? i don't know if i'm wrong but could i use autofac metadata or maybe named/keyed feature?
Stefano
2010-10-30 22:29:48
A:
Create a Autofac.Module in every plugin assembly. Register your plugin stuff there, and from your main application load your plugin dlls, look for Modules, register in container. Then resolve and have fun ;).
ppiotrowicz
2010-10-30 22:05:52