ExportBuilder.AddMetadata Method (String, Func<Type, Object>)

.NET Framework (current version)
 
System_CAPS_noteNote

The .NET API Reference documentation has a new home. Visit the .NET API Browser on docs.microsoft.com to see the new experience.

Specifies a metadata key/value pair to be added to the export.

Namespace:   System.ComponentModel.Composition.Registration
Assembly:  System.ComponentModel.Composition.Registration (in System.ComponentModel.Composition.Registration.dll)

public ExportBuilder AddMetadata(
	string name,
	Func<Type, object> itemFunc
)

Parameters

name
Type: System.String

The metadata key.

itemFunc
Type: System.Func<Type, Object>

A function that takes a type and returns the metadata value.

Return Value

Type: System.ComponentModel.Composition.Registration.ExportBuilder

The current object, to allow chaining.

.NET Framework
Available since 4.5
Return to top
Show: