IServiceScope Interface¶
The System.IDisposable.Dispose method ends the scope lifetime. Once Dispose
is called, any scoped services that have been resolved from
Microsoft.Extensions.DependencyInjection.IServiceScope.ServiceProvider will be
disposed.
- Namespace
Microsoft.Extensions.DependencyInjection- Assemblies
- Microsoft.Extensions.DependencyInjection.Abstractions
Syntax¶
public interface IServiceScope : IDisposable
-
interface
Microsoft.Extensions.DependencyInjection.IServiceScope
Properties¶
-
Microsoft.Extensions.DependencyInjection.IServiceScope.ServiceProvider¶ The
System.IServiceProviderused to resolve dependencies from the scope.Return type: System.IServiceProvider IServiceProvider ServiceProvider { get; }
-