Click or drag to resize

ComponentRegistration Constructor (Guid, IInstanceActivator, IComponentLifetime, InstanceSharing, InstanceOwnership, IResolvePipelineBuilder, IEnumerableService, IDictionaryString, Object, IComponentRegistration, RegistrationOptions)

Initializes a new instance of the ComponentRegistration class.

Namespace:  Autofac.Core.Registration
Assembly:  Autofac (in Autofac.dll) Version: 6.0.0+39696a967e8826f7f1ebc8c1ff4523c9dd75abe0
Syntax
public ComponentRegistration(
	Guid id,
	IInstanceActivator activator,
	IComponentLifetime lifetime,
	InstanceSharing sharing,
	InstanceOwnership ownership,
	IResolvePipelineBuilder pipelineBuilder,
	IEnumerable<Service> services,
	IDictionary<string, Object> metadata,
	IComponentRegistration target,
	RegistrationOptions options = RegistrationOptions.None
)

Parameters

id
Type: SystemGuid
Unique identifier for the component.
activator
Type: Autofac.CoreIInstanceActivator
Activator used to activate instances.
lifetime
Type: Autofac.CoreIComponentLifetime
Determines how the component will be associated with its lifetime.
sharing
Type: Autofac.CoreInstanceSharing
Whether the component is shared within its lifetime scope.
ownership
Type: Autofac.CoreInstanceOwnership
Whether the component instances are disposed at the end of their lifetimes.
pipelineBuilder
Type: Autofac.Core.Resolving.PipelineIResolvePipelineBuilder
The resolve pipeline builder for the registration.
services
Type: System.Collections.GenericIEnumerableService
Services the component provides.
metadata
Type: System.Collections.GenericIDictionaryString, Object
Data associated with the component.
target
Type: Autofac.CoreIComponentRegistration
The component registration upon which this registration is based.
options (Optional)
Type: Autofac.Core.RegistrationRegistrationOptions
Registration options.
See Also