So I have my directory catalog set up shown below:
DirectoryCatalog directoryCatalog = new DirectoryCatalog(@".\Plugins");
var catalog = new AggregateCatalog(directoryCatalog);
var container = new CompositionContainer(catalog);
container.ComposeParts(this);
Which will find any .dll's in my Plugins folder that meet my import criteria. Now To prevent reference clashes in my plugins I would like to put each plugin in a seperate folder.
e.g.
Plugins -> Plugin1 -> plugin1.dll
-> Plugin2 -> plugin2.dll
But my DirectoryCatalog doesn't find these plugins. Is it possible to implement this or do my plugin libraries have to be in that specified .\Plugins folder
You can solve your problem by adding multiple
DirectoryCatalogstoAggregateCatalog.Catalogsproperty like this: