6 references to AddKeyedSingleton
Microsoft.AspNetCore.Http.Extensions.Tests (1)
RequestDelegateGenerator\RequestDelegateCreationTests.KeyServices.cs (1)
239
var serviceProvider = CreateServiceProvider((serviceCollection) => serviceCollection.
AddKeyedSingleton
<global::Http.ExampleService>("example"));
Microsoft.AspNetCore.OpenApi (3)
Extensions\OpenApiServiceCollectionExtensions.cs (3)
106
services.
AddKeyedSingleton
<OpenApiSchemaService>(documentName);
107
services.
AddKeyedSingleton
<OpenApiSchemaStore>(documentName);
108
services.
AddKeyedSingleton
<OpenApiDocumentService>(documentName);
Microsoft.AspNetCore.OpenApi.Tests (1)
Services\OpenApiDocumentServiceTestsBase.cs (1)
264
serviceCollection.
AddKeyedSingleton
<OpenApiSchemaStore>("Test");
Microsoft.Extensions.DependencyInjection.AutoActivation (1)
AutoActivationExtensions.Keyed.cs (1)
168
.
AddKeyedSingleton
<TService>(serviceKey)