26 references to FromKeyedServicesAttribute
BasicWebSite (7)
Controllers\CustomServiceApiController.cs (7)
13public ActionResult<string> GetOk([FromKeyedServices("ok_service")] ICustomService service) 19public ActionResult<string> GetNotOk([FromKeyedServices("not_ok_service")] ICustomService service) 26[FromKeyedServices("ok_service")] ICustomService s1, 27[FromKeyedServices("not_ok_service")] ICustomService s2) 33public ActionResult<string> GetKeyNull([FromKeyedServices(null)] ICustomService service) 41public ActionResult<string> GetOptionalNotRegistered([FromKeyedServices("no_existing_key")] ICustomService? service) 51public ActionResult<string> GetRequiredNotRegistered([FromKeyedServices("no_existing_key")] ICustomService service)
Microsoft.AspNetCore.Mvc.Abstractions.Test (2)
ModelBinding\BindingInfoTest.cs (2)
298new FromKeyedServicesAttribute(key), 319new FromKeyedServicesAttribute(new object()),
Microsoft.AspNetCore.Mvc.ApiExplorer.Test (2)
DefaultApiDescriptionProviderTest.cs (1)
2476private void AcceptsFormatters_Services([FromServices] ITestService tempDataProvider, [FromKeyedServices("foo")] ITestService keyedTempDataProvider)
EndpointMetadataApiDescriptionProviderTest.cs (1)
425Assert.Empty(GetApiDescription(([FromKeyedServices("foo")] int foo) => { }).ParameterDescriptions);
Microsoft.AspNetCore.OpenApi.Tests (1)
Services\OpenApiGeneratorTests.cs (1)
413Assert.Empty(GetOpenApiOperation(([FromKeyedServices("foo")] int foo) => { }).Parameters);
Microsoft.AspNetCore.SignalR.Tests (8)
HubConnectionHandlerTestUtils\Hubs.cs (8)
1411public int MultipleSameKeyedServices([FromKeyedServices("service1")] Service1 service, [FromKeyedServices("service1")] Service1 service2) 1417public int KeyedService([FromKeyedServices("service1")] Service1 service) 1422public int KeyedServiceWithParam(int input, [FromKeyedServices("service1")] Service1 service) 1427public int KeyedServiceNonKeyedService(Service2 service2, [FromKeyedServices("service1")] Service1 service) 1432public int MultipleKeyedServices([FromKeyedServices("service1")] Service1 service, [FromKeyedServices("service2")] Service1 service2) 1441public void BadMethod([FromKeyedServices("service1")] [FromService] Service1 service)
ProxylessEndToEnd.ApiService (1)
Program.cs (1)
19app.MapGet("/redis", ([FromKeyedServices("redis")] IConnectionMultiplexer redis) =>
TestProject.IntegrationServiceA (3)
Garnet\GarnetExtensions.cs (1)
13private static async Task<IResult> VerifyGarnetAsync([FromKeyedServices("garnet")] IConnectionMultiplexer cm)
Redis\RedisExtensions.cs (1)
13private static async Task<IResult> VerifyRedisAsync([FromKeyedServices("redis")] IConnectionMultiplexer cm)
Valkey\ValkeyExtensions.cs (1)
13private static async Task<IResult> VerifyValkeyAsync([FromKeyedServices("valkey")] IConnectionMultiplexer cm)
WebPubSubWeb (2)
Program.cs (2)
34app.MapGet("/negotiate/chat", ([FromKeyedServices("chatHub")] WebPubSubServiceClient service) => 43app.MapGet("/negotiate/notification", ([FromKeyedServices("notificationHub")] WebPubSubServiceClient service) =>