Class ServiceCollectionExtensions
Inherited Members
Namespace: Microsoft.Extensions.DependencyInjection
Assembly: SoCore.dll
Syntax
public static class ServiceCollectionExtensions
Methods
AddScopedTypesFromAssembly<TBaseType>(IServiceCollection, Assembly)
Add all types identified by Microsoft.Extensions.DependencyInjection.ServiceCollectionExtensions.GetCreateableTypesFromAssembly``1(System.Reflection.Assembly) to IServiceCollection using AddScoped(IServiceCollection, Type)
Declaration
public static IServiceCollection AddScopedTypesFromAssembly<TBaseType>(this IServiceCollection serviceCollection, Assembly assemby)
Parameters
| Type | Name | Description |
|---|---|---|
| IServiceCollection | serviceCollection | Service collection to add types to. |
| Assembly | assemby | Assembly to parse |
Returns
| Type | Description |
|---|---|
| IServiceCollection |
Type Parameters
| Name | Description |
|---|---|
| TBaseType | Base types to look for implementations of. |