Show / Hide Table of Contents

Class ServiceCollectionExtensions

Inheritance
object
ServiceCollectionExtensions
Inherited Members
object.ToString()
object.Equals(object)
object.Equals(object, object)
object.ReferenceEquals(object, object)
object.GetHashCode()
object.GetType()
object.MemberwiseClone()
Namespace: Microsoft.Extensions.DependencyInjection
Assembly: SoCore.dll
Syntax
public static class ServiceCollectionExtensions

Methods

AddScopedTypesFromAssembly<TBaseType>(IServiceCollection, Assembly)

Add all types identified by Microsoft.Extensions.DependencyInjection.ServiceCollectionExtensions.GetCreateableTypesFromAssembly``1(System.Reflection.Assembly) to IServiceCollection using AddScoped(IServiceCollection, Type)

Declaration
public static IServiceCollection AddScopedTypesFromAssembly<TBaseType>(this IServiceCollection serviceCollection, Assembly assemby)
Parameters
Type Name Description
IServiceCollection serviceCollection

Service collection to add types to.

Assembly assemby

Assembly to parse

Returns
Type Description
IServiceCollection
Type Parameters
Name Description
TBaseType

Base types to look for implementations of.

© SuperOffice. All rights reserved.
SuperOffice |  Community |  Release Notes |  Privacy |  Site feedback |  Search Docs |  About Docs |  Contribute |  Back to top