ServiceProviderServiceExtensions extension

Extension methods for getting services from a ServiceProvider.

on

Methods

createAsyncScope() AsyncDisposable
Creates a new AsyncServiceScope that can be used to resolve scoped services.
createScope() → ServiceScope
Creates a new ServiceScope that can be used to resolve scoped services.
getRequiredService<T>() → T
Get service of type T from the ServiceProvider.