Skip to content

StashboxOptions Properties

ClassProperties3 members
Options for building the Stashbox Container
ConfigureContainerSection titled ConfigureContainernullableAction<ContainerConfigurator>
Configures the container (registration behavior, disposable transient tracking, etc.). Applied when the container is created and again once the service collection has been registered, so these settings win over the defaults set by the Microsoft.Extensions.DependencyInjection adapter.
public Action<ContainerConfigurator>? ConfigureContainer { get; set; }
ValidateLifetimesInDevelopmentSection titled ValidateLifetimesInDevelopmentbool
Enables lifetime validation when the environment is Development (defaults to true)
public bool ValidateLifetimesInDevelopment { get; set; }
Validates the whole container once the service provider has been built (defaults to false)
public bool ValidateOnBuild { get; set; }