ReplaceScoped<TService, TImplementation>(IServiceCollection)

public static IServiceCollection ReplaceScoped<TService, TImplementation>(IServiceCollection collection) where TImplementation : TService
Returns:
IServiceCollection

Parameters

collection IServiceCollection

Type Parameters

TService TImplementation TService

ReplaceScoped(IServiceCollection, Type, Type)

public static IServiceCollection ReplaceScoped(IServiceCollection collection, Type serviceType, Type implementationType)
Returns:
IServiceCollection

Parameters

collection IServiceCollection
serviceType Type
implementationType Type
In this article