Show / Hide Table of Contents

Class MefPartConventionsBuilder

Conventions builder for a specific part.

Inheritance
System.Object
MefPartConventionsBuilder
Implements
IPartConventionsBuilder
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 MefPartConventionsBuilder : IPartConventionsBuilder

Methods

| Improve this Doc View Source

AsServiceType(Type)

Indicates the declared service type. Typically this is the same as the contract type, but this may get overwritten, for example when declaring generic type services for collecting metadata.

Declaration
public IPartConventionsBuilder AsServiceType(Type serviceType)
Parameters
Type Name Description
System.Type serviceType

Type of the service.

Returns
Type Description
IPartConventionsBuilder

A part builder allowing further configuration of the part.

| Improve this Doc View Source

Export(Action<IExportConventionsBuilder>)

Exports the part using the specified conventions builder.

Declaration
public IPartConventionsBuilder Export(Action<IExportConventionsBuilder> conventionsBuilder = null)
Parameters
Type Name Description
System.Action<IExportConventionsBuilder> conventionsBuilder

The conventions builder.

Returns
Type Description
IPartConventionsBuilder

A part builder allowing further configuration of the part.

| Improve this Doc View Source

ExportInterface(Type, Action<Type, IExportConventionsBuilder>)

Select the interface on the part type that will be exported.

Declaration
public IPartConventionsBuilder ExportInterface(Type exportInterface, Action<Type, IExportConventionsBuilder> exportConfiguration = null)
Parameters
Type Name Description
System.Type exportInterface

The interface to export.

System.Action<System.Type, IExportConventionsBuilder> exportConfiguration

The export configuration.

Returns
Type Description
IPartConventionsBuilder

A part builder allowing further configuration of the part.

| Improve this Doc View Source

Scoped()

Mark the part as being shared within the scope.

Declaration
public IPartConventionsBuilder Scoped()
Returns
Type Description
IPartConventionsBuilder

A part builder allowing further configuration of the part.

| Improve this Doc View Source

SelectConstructor(Func<IEnumerable<ConstructorInfo>, ConstructorInfo>, Action<ParameterInfo, IImportConventionsBuilder>)

Select which of the available constructors will be used to instantiate the part.

Declaration
public IPartConventionsBuilder SelectConstructor(Func<IEnumerable<ConstructorInfo>, ConstructorInfo> constructorSelector, Action<ParameterInfo, IImportConventionsBuilder> importConfiguration = null)
Parameters
Type Name Description
System.Func<System.Collections.Generic.IEnumerable<System.Reflection.ConstructorInfo>, System.Reflection.ConstructorInfo> constructorSelector

Filter that selects a single constructor.

System.Action<System.Reflection.ParameterInfo, IImportConventionsBuilder> importConfiguration

Action configuring the parameters of the selected constructor.

Returns
Type Description
IPartConventionsBuilder

A part builder allowing further configuration of the part.

| Improve this Doc View Source

Singleton()

Mark the part as being shared within the entire composition.

Declaration
public IPartConventionsBuilder Singleton()
Returns
Type Description
IPartConventionsBuilder

A part builder allowing further configuration of the part.

Explicit Interface Implementations

| Improve this Doc View Source

IPartConventionsBuilder.AllowMultiple(Boolean)

Indicates that this service allows multiple registrations.

Declaration
IPartConventionsBuilder IPartConventionsBuilder.AllowMultiple(bool value)
Parameters
Type Name Description
System.Boolean value

True if multiple service registrations are allowed, false otherwise.

Returns
Type Description
IPartConventionsBuilder

A part builder allowing further configuration of the part.

Implements

IPartConventionsBuilder

Extension Methods

DynamicObjectExtensions.SetPropertyValue(Object, String, Object)
DynamicObjectExtensions.TrySetPropertyValue(Object, String, Object)
DynamicObjectExtensions.GetPropertyValue(Object, String)
DynamicObjectExtensions.TryGetPropertyValue(Object, String, out Object)
DynamicObjectExtensions.GetRuntimeTypeInfo(Object)
DynamicObjectExtensions.ToDynamic(Object)
DynamicObjectExtensions.ToExpando(Object)
BehaviorValue.ToBehaviorValue<TValue>(TValue)
CollectionExtensions.AddRange<T, TItem>(T, IEnumerable<TItem>)
LoggingExtensions.GetLogger(Object, IContext)
TypeExtensions.GetAbstractType(Object)
TypeExtensions.GetAbstractTypeInfo(Object)
ReflectionHelper.GetTypeInfo(Object)
EntityEntryExtensions.TryGetAttachedEntityEntry(Object)
  • Improve this Doc
  • View Source
Back to top Generated by DocFX