Skip to content

ASP.NET Core Scrutor extension for automatic registration of classes inherited from IScopedLifetime, ISelfScopedLifetime, ITransientLifetime, ISelfTransientLifetime, ISingletonLifetime, ISelfSingletonLifetime

License

Notifications You must be signed in to change notification settings

sefacan/Scrutor.AspNetCore

Folders and files

NameName
Last commit message
Last commit date

Latest commit

27d06e6 · Jun 29, 2022

History

17 Commits
Mar 16, 2021
Jun 29, 2022
Feb 15, 2020
Feb 15, 2020
Feb 15, 2020
Mar 3, 2021
Feb 15, 2020
Feb 15, 2020
Feb 27, 2020
Feb 15, 2020
Feb 27, 2020
Mar 3, 2021

Repository files navigation

Scrutor.AspNetCore

ASP.NET Core Scrutor extension for automatic registration of classes inherited from IScopedLifetime, ISelfScopedLifetime, ITransientLifetime, ISelfTransientLifetime, ISingletonLifetime, ISelfSingletonLifetime

Build Status

Build server Platform Status
Azure CI Pipelines All
Github Actions All
Travis CI Linux

Installation

Install the Scrutor.AspNetCore NuGet Package.

Package Manager Console

Install-Package Scrutor.AspNetCore

.NET Core CLI

dotnet add package Scrutor.AspNetCore

Usage

public void ConfigureServices(IServiceCollection services)
{
    //add to the end of the method
    services.AddAdvancedDependencyInjection();
}

public void Configure(IApplicationBuilder app, IWebHostEnvironment env)
{
    //add to the end of the method
    app.UseAdvancedDependencyInjection();
}

//usage without constructor classes
var service = ServiceLocator.Context.GetService<MyClass>();

About

ASP.NET Core Scrutor extension for automatic registration of classes inherited from IScopedLifetime, ISelfScopedLifetime, ITransientLifetime, ISelfTransientLifetime, ISingletonLifetime, ISelfSingletonLifetime

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages