2 implementations of IApplicationLifetime
Microsoft.AspNetCore.Hosting (2)
GenericHost\GenericWebHostApplicationLifetime.cs (1)
8
internal sealed class GenericWebHostApplicationLifetime :
IApplicationLifetime
Internal\ApplicationLifetime.cs (1)
17
internal sealed class ApplicationLifetime :
IApplicationLifetime
, Extensions.Hosting.IApplicationLifetime, IHostApplicationLifetime
17 references to IApplicationLifetime
InProcessWebSite (5)
src\Servers\IIS\IIS\test\testassets\InProcessWebSite\Startup.cs (3)
599
var
lifetime = ctx.RequestServices.GetService<Microsoft.AspNetCore.Hosting.
IApplicationLifetime
>();
995
ctx.RequestServices.GetService<Microsoft.AspNetCore.Hosting.
IApplicationLifetime
>().StopApplication();
src\Servers\IIS\IIS\test\testassets\InProcessWebSite\Startup.WebSockets.cs (2)
62
var
appLifetime = app.ApplicationServices.GetRequiredService<Microsoft.AspNetCore.Hosting.
IApplicationLifetime
>();
Microsoft.AspNetCore.Hosting (3)
GenericHost\GenericWebHostBuilder.cs (1)
61
services.AddSingleton<
IApplicationLifetime
, GenericWebHostApplicationLifetime>();
GenericHost\SlimWebHostBuilder.cs (1)
37
services.AddSingleton<
IApplicationLifetime
, GenericWebHostApplicationLifetime>();
Internal\WebHost.cs (1)
69
_applicationServiceCollection.AddSingleton<AspNetCore.Hosting.
IApplicationLifetime
>(services
Microsoft.AspNetCore.Hosting.Tests (9)
WebHostTests.cs (9)
165
var
lifetime2 = host.Services.GetRequiredService<AspNetCore.Hosting.
IApplicationLifetime
>();
411
var
applicationLifetime2 = host.Services.GetService<AspNetCore.Hosting.
IApplicationLifetime
>();
432
var
applicationLifetime2 = host.Services.GetService<AspNetCore.Hosting.
IApplicationLifetime
>();
682
var
applicationLifetime2 = host.Services.GetService<AspNetCore.Hosting.
IApplicationLifetime
>();
1151
AspNetCore.Hosting.
IApplicationLifetime
lifetime1,