13 instantiations of ServiceDescriptor
Microsoft.AspNetCore.Diagnostics.EntityFrameworkCore (1)
Microsoft.Extensions.DependencyInjection.Abstractions (12)
ServiceDescriptor.cs (6)
920return new ServiceDescriptor(serviceType, implementationInstance);
940return new ServiceDescriptor(serviceType, serviceKey, implementationInstance);
970return new ServiceDescriptor(serviceType, implementationType, lifetime);
989return new ServiceDescriptor(serviceType, serviceKey, implementationType, lifetime);
1003return new ServiceDescriptor(serviceType, implementationFactory, lifetime);
1018return new ServiceDescriptor(serviceType, serviceKey, implementationFactory, lifetime);
592 references to ServiceDescriptor
IntegrationTestsWebsite (1)
Microsoft.AspNetCore (7)
Microsoft.AspNetCore.Antiforgery (1)
Microsoft.AspNetCore.Authentication (2)
Microsoft.AspNetCore.Authentication.BearerToken (2)
Microsoft.AspNetCore.Authentication.Cookies (1)
Microsoft.AspNetCore.Authentication.JwtBearer (2)
Microsoft.AspNetCore.Authentication.Negotiate (2)
Microsoft.AspNetCore.Authentication.OAuth (1)
Microsoft.AspNetCore.Authentication.OpenIdConnect (2)
Microsoft.AspNetCore.Authentication.Twitter (1)
Microsoft.AspNetCore.Authentication.WsFederation (1)
Microsoft.AspNetCore.Authorization (6)
Microsoft.AspNetCore.Components (4)
Microsoft.AspNetCore.Components.Endpoints (1)
Microsoft.AspNetCore.Components.Endpoints.Tests (4)
Microsoft.AspNetCore.Components.Server (4)
Microsoft.AspNetCore.Components.Web (1)
Microsoft.AspNetCore.Components.WebAssembly.Server (2)
Microsoft.AspNetCore.Cors (2)
Microsoft.AspNetCore.DataProtection (5)
Microsoft.AspNetCore.DataProtection.Tests (4)
Microsoft.AspNetCore.Grpc.JsonTranscoding (2)
Microsoft.AspNetCore.Grpc.Swagger (2)
Microsoft.AspNetCore.Hosting (5)
Microsoft.AspNetCore.Hosting.Tests (4)
Microsoft.AspNetCore.Http.Connections (1)
Microsoft.AspNetCore.Http.Extensions (2)
Microsoft.AspNetCore.Http.Extensions.Tests (2)
Microsoft.AspNetCore.Http.Tests (1)
Microsoft.AspNetCore.HttpLogging (1)
Microsoft.AspNetCore.Identity (3)
Microsoft.AspNetCore.MiddlewareAnalysis (1)
Microsoft.AspNetCore.Mvc (2)
Microsoft.AspNetCore.Mvc.ApiExplorer (2)
Microsoft.AspNetCore.Mvc.Core (20)
DependencyInjection\MvcCoreServiceCollectionExtensions.cs (17)
135ServiceDescriptor.Transient<IConfigureOptions<MvcOptions>, MvcCoreMvcOptionsSetup>());
137ServiceDescriptor.Transient<IPostConfigureOptions<MvcOptions>, MvcCoreMvcOptionsSetup>());
139ServiceDescriptor.Transient<IConfigureOptions<ApiBehaviorOptions>, ApiBehaviorOptionsSetup>());
141ServiceDescriptor.Transient<IConfigureOptions<RouteOptions>, MvcCoreRouteOptionsSetup>());
149ServiceDescriptor.Transient<IApplicationModelProvider, DefaultApplicationModelProvider>());
151ServiceDescriptor.Transient<IApplicationModelProvider, ApiBehaviorApplicationModelProvider>());
153ServiceDescriptor.Transient<IActionDescriptorProvider, ControllerActionDescriptorProvider>());
164services.TryAddEnumerable(ServiceDescriptor.Transient<IActionConstraintProvider, DefaultActionConstraintProvider>());
167services.TryAddEnumerable(ServiceDescriptor.Singleton<MatcherPolicy, ActionConstraintMatcherPolicy>());
181ServiceDescriptor.Transient<IControllerPropertyActivator, DefaultControllerPropertyActivator>());
189ServiceDescriptor.Transient<IActionInvokerProvider, ControllerActionInvokerProvider>());
194ServiceDescriptor.Singleton<IFilterProvider, DefaultFilterProvider>());
209services.TryAdd(ServiceDescriptor.Transient<ICompositeMetadataDetailsProvider>(s =>
263services.TryAddEnumerable(ServiceDescriptor.Singleton<MatcherPolicy, DynamicControllerEndpointMatcherPolicy>());
264services.TryAddEnumerable(ServiceDescriptor.Singleton<IRequestDelegateFactory, ControllerRequestDelegateFactory>());
273services.TryAddEnumerable(ServiceDescriptor.Singleton<IStartupFilter, MiddlewareFilterBuilderStartupFilter>());
277services.TryAddEnumerable(ServiceDescriptor.Singleton<IProblemDetailsWriter, DefaultApiProblemDetailsWriter>());
Microsoft.AspNetCore.Mvc.Core.Test (6)
Microsoft.AspNetCore.Mvc.Cors (1)
Microsoft.AspNetCore.Mvc.DataAnnotations (2)
Microsoft.AspNetCore.Mvc.Formatters.Xml (4)
Microsoft.AspNetCore.Mvc.FunctionalTests (2)
Microsoft.AspNetCore.Mvc.Localization (3)
Microsoft.AspNetCore.Mvc.Localization.Test (7)
Microsoft.AspNetCore.Mvc.NewtonsoftJson (5)
Microsoft.AspNetCore.Mvc.NewtonsoftJson.Test (3)
Microsoft.AspNetCore.Mvc.Razor (3)
Microsoft.AspNetCore.Mvc.Razor.RuntimeCompilation (7)
Microsoft.AspNetCore.Mvc.Razor.RuntimeCompilation.Test (2)
Microsoft.AspNetCore.Mvc.Razor.Test (8)
Microsoft.AspNetCore.Mvc.RazorPages (15)
DependencyInjection\MvcRazorPagesMvcCoreBuilderExtensions.cs (15)
83ServiceDescriptor.Transient<IConfigureOptions<RazorViewEngineOptions>, RazorPagesRazorViewEngineOptionsSetup>());
86ServiceDescriptor.Transient<IConfigureOptions<RazorPagesOptions>, RazorPagesOptionsSetup>());
89services.TryAddEnumerable(ServiceDescriptor.Singleton<MatcherPolicy, DynamicPageEndpointMatcherPolicy>());
94var actionDescriptorProvider = services.FirstOrDefault(f =>
105ServiceDescriptor.Singleton<IActionDescriptorProvider, CompiledPageActionDescriptorProvider>());
108ServiceDescriptor.Singleton<IPageRouteModelProvider, CompiledPageRouteModelProvider>());
110services.TryAddEnumerable(ServiceDescriptor.Singleton<MatcherPolicy, DynamicPageEndpointMatcherPolicy>());
113ServiceDescriptor.Singleton<IPageApplicationModelProvider, DefaultPageApplicationModelProvider>());
115ServiceDescriptor.Singleton<IPageApplicationModelProvider, AutoValidateAntiforgeryPageApplicationModelProvider>());
117ServiceDescriptor.Singleton<IPageApplicationModelProvider, AuthorizationPageApplicationModelProvider>());
119ServiceDescriptor.Singleton<IPageApplicationModelProvider, TempDataFilterPageApplicationModelProvider>());
121ServiceDescriptor.Singleton<IPageApplicationModelProvider, ViewDataAttributePageApplicationModelProvider>());
123ServiceDescriptor.Singleton<IPageApplicationModelProvider, ResponseCacheFilterApplicationModelProvider>());
128ServiceDescriptor.Singleton<IActionInvokerProvider, PageActionInvokerProvider>());
130ServiceDescriptor.Singleton<IRequestDelegateFactory, PageRequestDelegateFactory>());
Microsoft.AspNetCore.Mvc.Test (9)
Microsoft.AspNetCore.Mvc.ViewFeatures (13)
Microsoft.AspNetCore.Mvc.ViewFeatures.Test (13)
Microsoft.AspNetCore.OpenApi (1)
Microsoft.AspNetCore.Routing (8)
Microsoft.AspNetCore.Routing.Microbenchmarks (1)
Microsoft.AspNetCore.Server.Kestrel (2)
Microsoft.AspNetCore.SignalR (1)
Microsoft.AspNetCore.SignalR.Client.FunctionalTests (1)
Microsoft.AspNetCore.SignalR.Microbenchmarks (1)
Microsoft.AspNetCore.SignalR.Protocols.Json (1)
Microsoft.AspNetCore.SignalR.Protocols.MessagePack (1)
Microsoft.AspNetCore.SignalR.Protocols.NewtonsoftJson (1)
Microsoft.AspNetCore.SignalR.Tests (2)
Microsoft.AspNetCore.SpaProxy (1)
Microsoft.AspNetCore.Tests (2)
Microsoft.Authentication.WebAssembly.Msal (1)
Microsoft.DotNet.Internal.DependencyInjection.Testing (2)
Microsoft.Extensions.Caching.Memory (2)
Microsoft.Extensions.Caching.SqlServer (1)
Microsoft.Extensions.Caching.SqlServer.Tests (2)
Microsoft.Extensions.Caching.StackExchangeRedis (1)
Microsoft.Extensions.Caching.StackExchangeRedis.Tests (3)
Microsoft.Extensions.DependencyInjection (34)
Microsoft.Extensions.DependencyInjection.Abstractions (268)
Extensions\ServiceCollectionDescriptorExtensions.cs (55)
19/// <param name="descriptor">The <see cref="ServiceDescriptor"/> to add.</param>
23ServiceDescriptor descriptor)
33/// Adds a sequence of <see cref="ServiceDescriptor"/> to the <paramref name="collection"/>.
36/// <param name="descriptors">The <see cref="ServiceDescriptor"/>s to add.</param>
40IEnumerable<ServiceDescriptor> descriptors)
45foreach (ServiceDescriptor? descriptor in descriptors)
58/// <param name="descriptor">The <see cref="ServiceDescriptor"/> to add.</param>
61ServiceDescriptor descriptor)
85/// <param name="descriptors">The <see cref="ServiceDescriptor"/>s to add.</param>
88IEnumerable<ServiceDescriptor> descriptors)
93foreach (ServiceDescriptor? d in descriptors)
112var descriptor = ServiceDescriptor.Transient(service, service);
133var descriptor = ServiceDescriptor.Transient(service, implementationType);
154var descriptor = ServiceDescriptor.Transient(service, implementationFactory);
202services.TryAdd(ServiceDescriptor.Transient(implementationFactory));
218var descriptor = ServiceDescriptor.Scoped(service, service);
239var descriptor = ServiceDescriptor.Scoped(service, implementationType);
260var descriptor = ServiceDescriptor.Scoped(service, implementationFactory);
308services.TryAdd(ServiceDescriptor.Scoped(implementationFactory));
324var descriptor = ServiceDescriptor.Singleton(service, service);
345var descriptor = ServiceDescriptor.Singleton(service, implementationType);
366var descriptor = ServiceDescriptor.Singleton(service, implementationFactory);
415var descriptor = ServiceDescriptor.Singleton(serviceType: typeof(TService), implementationInstance: instance);
432services.TryAdd(ServiceDescriptor.Singleton(implementationFactory));
436/// Adds a <see cref="ServiceDescriptor"/> if an existing descriptor with the same
437/// <see cref="ServiceDescriptor.ServiceType"/> and an implementation that does not already exist
441/// <param name="descriptor">The <see cref="ServiceDescriptor"/>.</param>
443/// Use <see cref="TryAddEnumerable(IServiceCollection, ServiceDescriptor)"/> when registering a service implementation of a
446/// <see cref="Add(IServiceCollection, ServiceDescriptor)"/> is not idempotent and can add
448/// <see cref="ServiceDescriptor"/> instances if called twice. Using
449/// <see cref="TryAddEnumerable(IServiceCollection, ServiceDescriptor)"/> will prevent registration
454ServiceDescriptor descriptor)
474ServiceDescriptor service = services[i];
488/// Adds the specified <see cref="ServiceDescriptor"/>s if an existing descriptor with the same
489/// <see cref="ServiceDescriptor.ServiceType"/> and an implementation that does not already exist
493/// <param name="descriptors">The <see cref="ServiceDescriptor"/>s.</param>
495/// Use <see cref="TryAddEnumerable(IServiceCollection, ServiceDescriptor)"/> when registering a service
498/// <see cref="Add(IServiceCollection, ServiceDescriptor)"/> is not idempotent and can add
500/// <see cref="ServiceDescriptor"/> instances if called twice. Using
501/// <see cref="TryAddEnumerable(IServiceCollection, ServiceDescriptor)"/> will prevent registration
506IEnumerable<ServiceDescriptor> descriptors)
511foreach (ServiceDescriptor? d in descriptors)
522/// <param name="descriptor">The <see cref="ServiceDescriptor"/> to replace with.</param>
526ServiceDescriptor descriptor)
568ServiceDescriptor? descriptor = collection[i];
Extensions\ServiceCollectionDescriptorExtensions.Keyed.cs (24)
27var descriptor = ServiceDescriptor.KeyedTransient(service, serviceKey, service);
50var descriptor = ServiceDescriptor.KeyedTransient(service, serviceKey, implementationType);
73var descriptor = ServiceDescriptor.KeyedTransient(service, serviceKey, implementationFactory);
125services.TryAdd(ServiceDescriptor.KeyedTransient(serviceKey, implementationFactory));
143var descriptor = ServiceDescriptor.KeyedScoped(service, serviceKey, service);
166var descriptor = ServiceDescriptor.KeyedScoped(service, serviceKey, implementationType);
189var descriptor = ServiceDescriptor.KeyedScoped(service, serviceKey, implementationFactory);
241services.TryAdd(ServiceDescriptor.KeyedScoped(serviceKey, implementationFactory));
259var descriptor = ServiceDescriptor.KeyedSingleton(service, serviceKey, service);
282var descriptor = ServiceDescriptor.KeyedSingleton(service, serviceKey, implementationType);
305var descriptor = ServiceDescriptor.KeyedSingleton(service, serviceKey, implementationFactory);
357var descriptor = ServiceDescriptor.KeyedSingleton(serviceType: typeof(TService), serviceKey, implementationInstance: instance);
376services.TryAdd(ServiceDescriptor.KeyedSingleton(serviceKey, implementationFactory));
403ServiceDescriptor? descriptor = collection[i];
ServiceDescriptor.cs (143)
17/// Initializes a new instance of <see cref="ServiceDescriptor"/> with the specified <paramref name="implementationType"/>.
31/// Initializes a new instance of <see cref="ServiceDescriptor"/> with the specified <paramref name="implementationType"/>.
34/// <param name="serviceKey">The <see cref="ServiceDescriptor.ServiceKey"/> of the service.</param>
51/// Initializes a new instance of <see cref="ServiceDescriptor"/> with the specified <paramref name="instance"/>
64/// Initializes a new instance of <see cref="ServiceDescriptor"/> with the specified <paramref name="instance"/>
68/// <param name="serviceKey">The <see cref="ServiceDescriptor.ServiceKey"/> of the service.</param>
83/// Initializes a new instance of <see cref="ServiceDescriptor"/> with the specified <paramref name="factory"/>.
101/// Initializes a new instance of <see cref="ServiceDescriptor"/> with the specified <paramref name="factory"/>.
104/// <param name="serviceKey">The <see cref="ServiceDescriptor.ServiceKey"/> of the service.</param>
338/// Creates an instance of <see cref="ServiceDescriptor"/> with the specified
344/// <returns>A new instance of <see cref="ServiceDescriptor"/>.</returns>
345public static ServiceDescriptor Transient<TService, [DynamicallyAccessedMembers(DynamicallyAccessedMemberTypes.PublicConstructors)] TImplementation>()
353/// Creates an instance of <see cref="ServiceDescriptor"/> with the specified
359/// <param name="serviceKey">The <see cref="ServiceDescriptor.ServiceKey"/> of the service.</param>
360/// <returns>A new instance of <see cref="ServiceDescriptor"/>.</returns>
361public static ServiceDescriptor KeyedTransient<TService, [DynamicallyAccessedMembers(DynamicallyAccessedMemberTypes.PublicConstructors)] TImplementation>(object? serviceKey)
369/// Creates an instance of <see cref="ServiceDescriptor"/> with the specified
375/// <returns>A new instance of <see cref="ServiceDescriptor"/>.</returns>
376public static ServiceDescriptor Transient(
387/// Creates an instance of <see cref="ServiceDescriptor"/> with the specified
392/// <param name="serviceKey">The <see cref="ServiceDescriptor.ServiceKey"/> of the service.</param>
394/// <returns>A new instance of <see cref="ServiceDescriptor"/>.</returns>
395public static ServiceDescriptor KeyedTransient(
407/// Creates an instance of <see cref="ServiceDescriptor"/> with the specified
415/// <returns>A new instance of <see cref="ServiceDescriptor"/>.</returns>
416public static ServiceDescriptor Transient<TService, TImplementation>(
427/// Creates an instance of <see cref="ServiceDescriptor"/> with the specified
434/// <param name="serviceKey">The <see cref="ServiceDescriptor.ServiceKey"/> of the service.</param>
436/// <returns>A new instance of <see cref="ServiceDescriptor"/>.</returns>
437public static ServiceDescriptor KeyedTransient<TService, TImplementation>(
449/// Creates an instance of <see cref="ServiceDescriptor"/> with the specified
455/// <returns>A new instance of <see cref="ServiceDescriptor"/>.</returns>
456public static ServiceDescriptor Transient<TService>(Func<IServiceProvider, TService> implementationFactory)
465/// Creates an instance of <see cref="ServiceDescriptor"/> with the specified
470/// <param name="serviceKey">The <see cref="ServiceDescriptor.ServiceKey"/> of the service.</param>
472/// <returns>A new instance of <see cref="ServiceDescriptor"/>.</returns>
473public static ServiceDescriptor KeyedTransient<TService>(object? serviceKey, Func<IServiceProvider, object?, TService> implementationFactory)
482/// Creates an instance of <see cref="ServiceDescriptor"/> with the specified
488/// <returns>A new instance of <see cref="ServiceDescriptor"/>.</returns>
489public static ServiceDescriptor Transient(Type service, Func<IServiceProvider, object> implementationFactory)
498/// Creates an instance of <see cref="ServiceDescriptor"/> with the specified
503/// <param name="serviceKey">The <see cref="ServiceDescriptor.ServiceKey"/> of the service.</param>
505/// <returns>A new instance of <see cref="ServiceDescriptor"/>.</returns>
506public static ServiceDescriptor KeyedTransient(Type service, object? serviceKey, Func<IServiceProvider, object?, object> implementationFactory)
515/// Creates an instance of <see cref="ServiceDescriptor"/> with the specified
521/// <returns>A new instance of <see cref="ServiceDescriptor"/>.</returns>
522public static ServiceDescriptor Scoped<TService, [DynamicallyAccessedMembers(DynamicallyAccessedMemberTypes.PublicConstructors)] TImplementation>()
530/// Creates an instance of <see cref="ServiceDescriptor"/> with the specified
536/// <param name="serviceKey">The <see cref="ServiceDescriptor.ServiceKey"/> of the service.</param>
537/// <returns>A new instance of <see cref="ServiceDescriptor"/>.</returns>
538public static ServiceDescriptor KeyedScoped<TService, [DynamicallyAccessedMembers(DynamicallyAccessedMemberTypes.PublicConstructors)] TImplementation>(object? serviceKey)
546/// Creates an instance of <see cref="ServiceDescriptor"/> with the specified
552/// <returns>A new instance of <see cref="ServiceDescriptor"/>.</returns>
553public static ServiceDescriptor Scoped(
561/// Creates an instance of <see cref="ServiceDescriptor"/> with the specified
566/// <param name="serviceKey">The <see cref="ServiceDescriptor.ServiceKey"/> of the service.</param>
568/// <returns>A new instance of <see cref="ServiceDescriptor"/>.</returns>
569public static ServiceDescriptor KeyedScoped(
578/// Creates an instance of <see cref="ServiceDescriptor"/> with the specified
586/// <returns>A new instance of <see cref="ServiceDescriptor"/>.</returns>
587public static ServiceDescriptor Scoped<TService, TImplementation>(
598/// Creates an instance of <see cref="ServiceDescriptor"/> with the specified
605/// <param name="serviceKey">The <see cref="ServiceDescriptor.ServiceKey"/> of the service.</param>
607/// <returns>A new instance of <see cref="ServiceDescriptor"/>.</returns>
608public static ServiceDescriptor KeyedScoped<TService, TImplementation>(
620/// Creates an instance of <see cref="ServiceDescriptor"/> with the specified
626/// <returns>A new instance of <see cref="ServiceDescriptor"/>.</returns>
627public static ServiceDescriptor Scoped<TService>(Func<IServiceProvider, TService> implementationFactory)
636/// Creates an instance of <see cref="ServiceDescriptor"/> with the specified
641/// <param name="serviceKey">The <see cref="ServiceDescriptor.ServiceKey"/> of the service.</param>
643/// <returns>A new instance of <see cref="ServiceDescriptor"/>.</returns>
644public static ServiceDescriptor KeyedScoped<TService>(object? serviceKey, Func<IServiceProvider, object?, TService> implementationFactory)
653/// Creates an instance of <see cref="ServiceDescriptor"/> with the specified
659/// <returns>A new instance of <see cref="ServiceDescriptor"/>.</returns>
660public static ServiceDescriptor Scoped(Type service, Func<IServiceProvider, object> implementationFactory)
669/// Creates an instance of <see cref="ServiceDescriptor"/> with the specified
674/// <param name="serviceKey">The <see cref="ServiceDescriptor.ServiceKey"/> of the service.</param>
676/// <returns>A new instance of <see cref="ServiceDescriptor"/>.</returns>
677public static ServiceDescriptor KeyedScoped(Type service, object? serviceKey, Func<IServiceProvider, object?, object> implementationFactory)
686/// Creates an instance of <see cref="ServiceDescriptor"/> with the specified
692/// <returns>A new instance of <see cref="ServiceDescriptor"/>.</returns>
693public static ServiceDescriptor Singleton<TService, [DynamicallyAccessedMembers(DynamicallyAccessedMemberTypes.PublicConstructors)] TImplementation>()
701/// Creates an instance of <see cref="ServiceDescriptor"/> with the specified
707/// <param name="serviceKey">The <see cref="ServiceDescriptor.ServiceKey"/> of the service.</param>
708/// <returns>A new instance of <see cref="ServiceDescriptor"/>.</returns>
709public static ServiceDescriptor KeyedSingleton<TService, [DynamicallyAccessedMembers(DynamicallyAccessedMemberTypes.PublicConstructors)] TImplementation>(
718/// Creates an instance of <see cref="ServiceDescriptor"/> with the specified
724/// <returns>A new instance of <see cref="ServiceDescriptor"/>.</returns>
725public static ServiceDescriptor Singleton(
736/// Creates an instance of <see cref="ServiceDescriptor"/> with the specified
741/// <param name="serviceKey">The <see cref="ServiceDescriptor.ServiceKey"/> of the service.</param>
743/// <returns>A new instance of <see cref="ServiceDescriptor"/>.</returns>
744public static ServiceDescriptor KeyedSingleton(
756/// Creates an instance of <see cref="ServiceDescriptor"/> with the specified
764/// <returns>A new instance of <see cref="ServiceDescriptor"/>.</returns>
765public static ServiceDescriptor Singleton<TService, TImplementation>(
776/// Creates an instance of <see cref="ServiceDescriptor"/> with the specified
783/// <param name="serviceKey">The <see cref="ServiceDescriptor.ServiceKey"/> of the service.</param>
785/// <returns>A new instance of <see cref="ServiceDescriptor"/>.</returns>
786public static ServiceDescriptor KeyedSingleton<TService, TImplementation>(
798/// Creates an instance of <see cref="ServiceDescriptor"/> with the specified
804/// <returns>A new instance of <see cref="ServiceDescriptor"/>.</returns>
805public static ServiceDescriptor Singleton<TService>(Func<IServiceProvider, TService> implementationFactory)
814/// Creates an instance of <see cref="ServiceDescriptor"/> with the specified
819/// <param name="serviceKey">The <see cref="ServiceDescriptor.ServiceKey"/> of the service.</param>
821/// <returns>A new instance of <see cref="ServiceDescriptor"/>.</returns>
822public static ServiceDescriptor KeyedSingleton<TService>(
833/// Creates an instance of <see cref="ServiceDescriptor"/> with the specified
839/// <returns>A new instance of <see cref="ServiceDescriptor"/>.</returns>
840public static ServiceDescriptor Singleton(
851/// Creates an instance of <see cref="ServiceDescriptor"/> with the specified
856/// <param name="serviceKey">The <see cref="ServiceDescriptor.ServiceKey"/> of the service.</param>
858/// <returns>A new instance of <see cref="ServiceDescriptor"/>.</returns>
859public static ServiceDescriptor KeyedSingleton(
871/// Creates an instance of <see cref="ServiceDescriptor"/> with the specified
877/// <returns>A new instance of <see cref="ServiceDescriptor"/>.</returns>
878public static ServiceDescriptor Singleton<TService>(TService implementationInstance)
887/// Creates an instance of <see cref="ServiceDescriptor"/> with the specified
892/// <param name="serviceKey">The <see cref="ServiceDescriptor.ServiceKey"/> of the service.</param>
894/// <returns>A new instance of <see cref="ServiceDescriptor"/>.</returns>
895public static ServiceDescriptor KeyedSingleton<TService>(
906/// Creates an instance of <see cref="ServiceDescriptor"/> with the specified
912/// <returns>A new instance of <see cref="ServiceDescriptor"/>.</returns>
913public static ServiceDescriptor Singleton(
924/// Creates an instance of <see cref="ServiceDescriptor"/> with the specified
929/// <param name="serviceKey">The <see cref="ServiceDescriptor.ServiceKey"/> of the service.</param>
931/// <returns>A new instance of <see cref="ServiceDescriptor"/>.</returns>
932public static ServiceDescriptor KeyedSingleton(
943private static ServiceDescriptor DescribeKeyed<TService, [DynamicallyAccessedMembers(DynamicallyAccessedMemberTypes.PublicConstructors)] TImplementation>(
957/// Creates an instance of <see cref="ServiceDescriptor"/> with the specified
964/// <returns>A new instance of <see cref="ServiceDescriptor"/>.</returns>
965public static ServiceDescriptor Describe(
974/// Creates an instance of <see cref="ServiceDescriptor"/> with the specified
979/// <param name="serviceKey">The <see cref="ServiceDescriptor.ServiceKey"/> of the service.</param>
982/// <returns>A new instance of <see cref="ServiceDescriptor"/>.</returns>
983public static ServiceDescriptor DescribeKeyed(
993/// Creates an instance of <see cref="ServiceDescriptor"/> with the specified
1000/// <returns>A new instance of <see cref="ServiceDescriptor"/>.</returns>
1001public static ServiceDescriptor Describe(Type serviceType, Func<IServiceProvider, object> implementationFactory, ServiceLifetime lifetime)
1007/// Creates an instance of <see cref="ServiceDescriptor"/> with the specified
1012/// <param name="serviceKey">The <see cref="ServiceDescriptor.ServiceKey"/> of the service.</param>
1015/// <returns>A new instance of <see cref="ServiceDescriptor"/>.</returns>
1016public static ServiceDescriptor DescribeKeyed(Type serviceType, object? serviceKey, Func<IServiceProvider, object?, object> implementationFactory, ServiceLifetime lifetime)
Microsoft.Extensions.Diagnostics.Abstractions (2)
Microsoft.Extensions.Diagnostics.HealthChecks (1)
Microsoft.Extensions.Hosting.Abstractions (2)
Microsoft.Extensions.Http (13)
Microsoft.Extensions.Http.Polly (3)
Microsoft.Extensions.Logging (4)
Microsoft.Extensions.Logging.AzureAppServices (2)
Microsoft.Extensions.Logging.Configuration (2)
Microsoft.Extensions.Logging.Console (6)
Microsoft.Extensions.Logging.Debug (1)
Microsoft.Extensions.Logging.EventLog (2)
Microsoft.Extensions.Logging.EventSource (3)
Microsoft.Extensions.Options (6)
Mvc.RoutingWebSite (1)