IRegistrationBuilderTLimit, TActivatorData, TRegistrationStyleWithMetadataTMetadata Method (ActionMetadataConfigurationTMetadata) |
Associates data with the component.
Namespace:
Autofac.Builder
Assembly:
Autofac (in Autofac.dll) Version: 6.0.0+39696a967e8826f7f1ebc8c1ff4523c9dd75abe0
Syntax IRegistrationBuilder<TLimit, TActivatorData, TRegistrationStyle> WithMetadata<TMetadata>(
Action<MetadataConfiguration<TMetadata>> configurationAction
)
Function WithMetadata(Of TMetadata) (
configurationAction As Action(Of MetadataConfiguration(Of TMetadata))
) As IRegistrationBuilder(Of TLimit, TActivatorData, TRegistrationStyle)
Parameters
- configurationAction
- Type: SystemActionMetadataConfigurationTMetadata
The action used to configure the metadata.
Type Parameters
- TMetadata
- A type with properties whose names correspond to the
property names to configure.
Return Value
Type:
IRegistrationBuilderTLimit,
TActivatorData,
TRegistrationStyleA registration builder allowing further configuration of the component.
See Also