Class MefModuleInitializer
Exports the ModuleInitializer using the Managed Extensibility Framework (MEF).
Implements
System.Object.Equals(System.Object)
System.Object.Equals(System.Object, System.Object)
System.Object.GetHashCode()
System.Object.GetType()
System.Object.MemberwiseClone()
System.Object.ReferenceEquals(System.Object, System.Object)
System.Object.ToString()
Namespace: Sartorius.SAF.Presentation.MefExtensions
Assembly: Sartorius.SAF.Presentation.dll
Syntax
[Export(typeof(IModuleInitializer))]
public class MefModuleInitializer : ModuleInitializer, IModuleInitializer
Remarks
This allows the MefBootstrapper to provide this class as a default implementation. If another implementation is found, this export will not be used.
Constructors
View SourceMefModuleInitializer(IServiceLocator, DownloadedPartCatalogCollection, AggregateCatalog)
Initializes a new instance of the MefModuleInitializer class.
Declaration
[ImportingConstructor]
public MefModuleInitializer(IServiceLocator serviceLocator, DownloadedPartCatalogCollection downloadedPartCatalogs, AggregateCatalog aggregateCatalog)
Parameters
Type | Name | Description |
---|---|---|
CommonServiceLocator.IServiceLocator | serviceLocator | The container that will be used to resolve the modules by specifying its type. |
DownloadedPartCatalogCollection | downloadedPartCatalogs | The downloaded part catalogs. |
System.ComponentModel.Composition.Hosting.AggregateCatalog | aggregateCatalog | The aggregate catalog. |
Methods
View SourceCreateModule(ModuleInfo)
Uses the container to resolve a new IModule by specifying its System.Type.
Declaration
protected override IModule CreateModule(ModuleInfo moduleInfo)
Parameters
Type | Name | Description |
---|---|---|
ModuleInfo | moduleInfo | The module to create. |
Returns
Type | Description |
---|---|
IModule | A new instance of the module specified by |