ComponentRegistrarSetAutoActivateTReflectionActivatorData, TSingleRegistrationStyle Method |
Namespace: Autofac.Configuration.Core
protected virtual void SetAutoActivate<TReflectionActivatorData, TSingleRegistrationStyle>( IConfiguration component, IRegistrationBuilder<Object, TReflectionActivatorData, TSingleRegistrationStyle> registrar ) where TReflectionActivatorData : ReflectionActivatorData where TSingleRegistrationStyle : SingleRegistrationStyle
Exception | Condition |
---|---|
ArgumentNullException | Thrown if registrar or component is . |
InvalidOperationException | Thrown if the value for autoActivate is not part of the recognized grammar. |
By default, this implementation understands , empty, or values (false, 0, no) to mean "not auto-activated" and values (true, 1, yes) to mean auto activation should occur.
You may override this method to extend the available grammar for auto activation settings.