Share via


ServiceDescriptor.Describe Method

Definition

Overloads

Describe(Type, Func<IServiceProvider,Object>, ServiceLifetime)

Creates an instance of ServiceDescriptor with the specified serviceType, implementationFactory, and lifetime.

Describe(Type, Type, ServiceLifetime)

Creates an instance of ServiceDescriptor with the specified serviceType, implementationType, and lifetime.

Describe(Type, Func<IServiceProvider,Object>, ServiceLifetime)

Source:
ServiceDescriptor.cs
Source:
ServiceDescriptor.cs
Source:
ServiceDescriptor.cs
Source:
ServiceDescriptor.cs
Source:
ServiceDescriptor.cs

Creates an instance of ServiceDescriptor with the specified serviceType, implementationFactory, and lifetime.

public:
 static Microsoft::Extensions::DependencyInjection::ServiceDescriptor ^ Describe(Type ^ serviceType, Func<IServiceProvider ^, System::Object ^> ^ implementationFactory, Microsoft::Extensions::DependencyInjection::ServiceLifetime lifetime);
public static Microsoft.Extensions.DependencyInjection.ServiceDescriptor Describe (Type serviceType, Func<IServiceProvider,object> implementationFactory, Microsoft.Extensions.DependencyInjection.ServiceLifetime lifetime);
static member Describe : Type * Func<IServiceProvider, obj> * Microsoft.Extensions.DependencyInjection.ServiceLifetime -> Microsoft.Extensions.DependencyInjection.ServiceDescriptor
Public Shared Function Describe (serviceType As Type, implementationFactory As Func(Of IServiceProvider, Object), lifetime As ServiceLifetime) As ServiceDescriptor

Parameters

serviceType
Type

The type of the service.

implementationFactory
Func<IServiceProvider,Object>

A factory to create new instances of the service implementation.

lifetime
ServiceLifetime

The lifetime of the service.

Returns

A new instance of ServiceDescriptor.

Applies to

Describe(Type, Type, ServiceLifetime)

Source:
ServiceDescriptor.cs
Source:
ServiceDescriptor.cs
Source:
ServiceDescriptor.cs
Source:
ServiceDescriptor.cs
Source:
ServiceDescriptor.cs

Creates an instance of ServiceDescriptor with the specified serviceType, implementationType, and lifetime.

public:
 static Microsoft::Extensions::DependencyInjection::ServiceDescriptor ^ Describe(Type ^ serviceType, Type ^ implementationType, Microsoft::Extensions::DependencyInjection::ServiceLifetime lifetime);
public static Microsoft.Extensions.DependencyInjection.ServiceDescriptor Describe (Type serviceType, Type implementationType, Microsoft.Extensions.DependencyInjection.ServiceLifetime lifetime);
static member Describe : Type * Type * Microsoft.Extensions.DependencyInjection.ServiceLifetime -> Microsoft.Extensions.DependencyInjection.ServiceDescriptor
Public Shared Function Describe (serviceType As Type, implementationType As Type, lifetime As ServiceLifetime) As ServiceDescriptor

Parameters

serviceType
Type

The type of the service.

implementationType
Type

The type of the implementation.

lifetime
ServiceLifetime

The lifetime of the service.

Returns

A new instance of ServiceDescriptor.

Applies to