Class MefExportConventionsBuilder
Export conventions builder for MEF.
Inheritance
System.Object
MefExportConventionsBuilder
Implements
Inherited Members
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: Kephas.Composition.Mef.Conventions
Assembly: Kephas.Composition.Mef.dll
Syntax
public class MefExportConventionsBuilder : IExportConventionsBuilder
Methods
| Improve this Doc View SourceAddMetadata(String, Func<Type, Object>)
Add export metadata to the export.
Declaration
public IExportConventionsBuilder AddMetadata(string name, Func<Type, object> getValueFromPartType)
Parameters
Type | Name | Description |
---|---|---|
System.String | name | The name of the metadata item. |
System.Func<System.Type, System.Object> | getValueFromPartType | A function that calculates the metadata value based on the type. |
Returns
Type | Description |
---|---|
IExportConventionsBuilder | An export builder allowing further configuration. |
AddMetadata(String, Object)
Add export metadata to the export.
Declaration
public IExportConventionsBuilder AddMetadata(string name, object value)
Parameters
Type | Name | Description |
---|---|---|
System.String | name | The name of the metadata item. |
System.Object | value | The metadata value. |
Returns
Type | Description |
---|---|
IExportConventionsBuilder | An export builder allowing further configuration. |
AsContractType(Type)
Specify the contract type for the export.
Declaration
public IExportConventionsBuilder AsContractType(Type contractType)
Parameters
Type | Name | Description |
---|---|---|
System.Type | contractType | The contract type. |
Returns
Type | Description |
---|---|
IExportConventionsBuilder | An export builder allowing further configuration. |