63 references to Scoped
Aspire.Components.Common.Tests (1)
ConformanceTests.cs (1)
197case ServiceLifetime.Scoped:
Aspire.Microsoft.Data.SqlClient.Tests (1)
ConformanceTests.cs (1)
20protected override ServiceLifetime ServiceLifetime => ServiceLifetime.Scoped;
Microsoft.AspNetCore.Identity.FunctionalTests (1)
Infrastructure\FunctionalTestsServiceCollectionExtensions.cs (1)
24ServiceLifetime.Scoped);
Microsoft.DotNet.Internal.DependencyInjection.Testing (2)
DependencyInjectionValidation.cs (2)
70if (!IsTypeResolvable(scopedType, services, allErrors, ServiceLifetime.Scoped)) 149parameterService.Lifetime == ServiceLifetime.Scoped)
Microsoft.Extensions.Caching.SqlServer.Tests (1)
SqlServerCacheServicesExtensionsTest.cs (1)
51Assert.Equal(ServiceLifetime.Scoped, distributedCache.Lifetime);
Microsoft.Extensions.Caching.StackExchangeRedis.Tests (2)
CacheServiceExtensionsTests.cs (2)
48Assert.Equal(ServiceLifetime.Scoped, distributedCache.Lifetime); 119Assert.Equal(ServiceLifetime.Scoped, distributedCache.Lifetime);
Microsoft.Extensions.DependencyInjection (5)
DependencyInjectionEventSource.cs (1)
201case ServiceLifetime.Scoped:
ServiceLookup\CallSiteValidator.cs (3)
28nameof(ServiceLifetime.Scoped).ToLowerInvariant())); 35nameof(ServiceLifetime.Scoped).ToLowerInvariant())); 59nameof(ServiceLifetime.Scoped).ToLowerInvariant(),
ServiceLookup\ResultCache.cs (1)
30case ServiceLifetime.Scoped:
Microsoft.Extensions.DependencyInjection.Abstractions (50)
Extensions\ServiceCollectionDescriptorExtensions.cs (6)
206/// Adds the specified <paramref name="service"/> as a <see cref="ServiceLifetime.Scoped"/> service 223/// Adds the specified <paramref name="service"/> as a <see cref="ServiceLifetime.Scoped"/> service 244/// Adds the specified <paramref name="service"/> as a <see cref="ServiceLifetime.Scoped"/> service 265/// Adds the specified <typeparamref name="TService"/> as a <see cref="ServiceLifetime.Scoped"/> service 279/// Adds the specified <typeparamref name="TService"/> as a <see cref="ServiceLifetime.Scoped"/> service 296/// Adds the specified <typeparamref name="TService"/> as a <see cref="ServiceLifetime.Scoped"/> service
Extensions\ServiceCollectionDescriptorExtensions.Keyed.cs (6)
129/// Adds the specified <paramref name="service"/> as a <see cref="ServiceLifetime.Scoped"/> service 148/// Adds the specified <paramref name="service"/> as a <see cref="ServiceLifetime.Scoped"/> service 171/// Adds the specified <paramref name="service"/> as a <see cref="ServiceLifetime.Scoped"/> service 194/// Adds the specified <typeparamref name="TService"/> as a <see cref="ServiceLifetime.Scoped"/> service 209/// Adds the specified <typeparamref name="TService"/> as a <see cref="ServiceLifetime.Scoped"/> service 227/// Adds the specified <typeparamref name="TService"/> as a <see cref="ServiceLifetime.Scoped"/> service
ServiceCollectionServiceExtensions.cs (9)
165/// <seealso cref="ServiceLifetime.Scoped"/> 175return Add(services, serviceType, implementationType, ServiceLifetime.Scoped); 187/// <seealso cref="ServiceLifetime.Scoped"/> 197return Add(services, serviceType, implementationFactory, ServiceLifetime.Scoped); 209/// <seealso cref="ServiceLifetime.Scoped"/> 226/// <seealso cref="ServiceLifetime.Scoped"/> 244/// <seealso cref="ServiceLifetime.Scoped"/> 262/// <seealso cref="ServiceLifetime.Scoped"/> 285/// <seealso cref="ServiceLifetime.Scoped"/>
ServiceCollectionServiceExtensions.Keyed.cs (9)
182/// <seealso cref="ServiceLifetime.Scoped"/> 193return AddKeyed(services, serviceType, serviceKey, implementationType, ServiceLifetime.Scoped); 206/// <seealso cref="ServiceLifetime.Scoped"/> 217return AddKeyed(services, serviceType, serviceKey, implementationFactory, ServiceLifetime.Scoped); 230/// <seealso cref="ServiceLifetime.Scoped"/> 250/// <seealso cref="ServiceLifetime.Scoped"/> 270/// <seealso cref="ServiceLifetime.Scoped"/> 291/// <seealso cref="ServiceLifetime.Scoped"/> 316/// <seealso cref="ServiceLifetime.Scoped"/>
ServiceDescriptor.cs (20)
517/// and the <see cref="ServiceLifetime.Scoped"/> lifetime. 526return DescribeKeyed<TService, TImplementation>(null, ServiceLifetime.Scoped); 532/// and the <see cref="ServiceLifetime.Scoped"/> lifetime. 542return DescribeKeyed<TService, TImplementation>(serviceKey, ServiceLifetime.Scoped); 548/// and the <see cref="ServiceLifetime.Scoped"/> lifetime. 557return Describe(service, implementationType, ServiceLifetime.Scoped); 563/// and the <see cref="ServiceLifetime.Scoped"/> lifetime. 574return DescribeKeyed(service, serviceKey, implementationType, ServiceLifetime.Scoped); 581/// and the <see cref="ServiceLifetime.Scoped"/> lifetime. 594return Describe(typeof(TService), implementationFactory, ServiceLifetime.Scoped); 601/// and the <see cref="ServiceLifetime.Scoped"/> lifetime. 616return DescribeKeyed(typeof(TService), serviceKey, implementationFactory, ServiceLifetime.Scoped); 622/// and the <see cref="ServiceLifetime.Scoped"/> lifetime. 632return Describe(typeof(TService), implementationFactory, ServiceLifetime.Scoped); 638/// and the <see cref="ServiceLifetime.Scoped"/> lifetime. 649return DescribeKeyed(typeof(TService), serviceKey, implementationFactory, ServiceLifetime.Scoped); 655/// and the <see cref="ServiceLifetime.Scoped"/> lifetime. 665return Describe(service, implementationFactory, ServiceLifetime.Scoped); 671/// and the <see cref="ServiceLifetime.Scoped"/> lifetime. 682return DescribeKeyed(service, serviceKey, implementationFactory, ServiceLifetime.Scoped);