ServiceDescriptor Класс
Определение
Важно!
Некоторые сведения относятся к предварительной версии продукта, в которую до выпуска могут быть внесены существенные изменения. Майкрософт не предоставляет никаких гарантий, явных или подразумеваемых, относительно приведенных здесь сведений.
Описывает службу со своим типом службы, реализацией и временем существования.
public ref class ServiceDescriptor
public class ServiceDescriptor
type ServiceDescriptor = class
Public Class ServiceDescriptor
- Наследование
-
ServiceDescriptor
Конструкторы
| Имя | Описание |
|---|---|
| ServiceDescriptor(Type, Func<IServiceProvider,Object>, ServiceLifetime) |
Инициализирует новый экземпляр ServiceDescriptor с указанным |
| ServiceDescriptor(Type, Object, Func<IServiceProvider,Object,Object>, ServiceLifetime) |
Инициализирует новый экземпляр ServiceDescriptor с указанным |
| ServiceDescriptor(Type, Object, Object) |
Инициализирует новый экземпляр ServiceDescriptor с указанным |
| ServiceDescriptor(Type, Object, Type, ServiceLifetime) |
Инициализирует новый экземпляр ServiceDescriptor с указанным |
| ServiceDescriptor(Type, Object) |
Инициализирует новый экземпляр ServiceDescriptor с указанным |
| ServiceDescriptor(Type, Type, ServiceLifetime) |
Инициализирует новый экземпляр ServiceDescriptor с указанным |
Свойства
| Имя | Описание |
|---|---|
| ImplementationFactory |
Возвращает фабрику, используемую для создания экземпляра службы, или возвращает, |
| ImplementationInstance |
Возвращает экземпляр, реализующий службу, или возвращает |
| ImplementationType |
Возвращает объект Type , реализующий службу или возвращающий |
| IsKeyedService |
Указывает, является ли служба ключом. |
| KeyedImplementationFactory |
Возвращает фабрику, используемую для создания экземпляров службы keyed, или создает исключение InvalidOperationException , если IsKeyedService это |
| KeyedImplementationInstance |
Возвращает экземпляр, реализующий службу, или вызывает InvalidOperationException , если IsKeyedService это |
| KeyedImplementationType |
Возвращает объект Type , реализующий службу, или вызывает InvalidOperationException , если IsKeyedService это |
| Lifetime |
ServiceLifetime Возвращает службу. |
| ServiceKey |
При необходимости получите ключ службы. |
| ServiceType |
Type Возвращает службу. |
Методы
| Имя | Описание |
|---|---|
| Describe(Type, Func<IServiceProvider,Object>, ServiceLifetime) |
Создает экземпляр ServiceDescriptor с указанным |
| Describe(Type, Type, ServiceLifetime) |
Создает экземпляр ServiceDescriptor с указанным |
| DescribeKeyed(Type, Object, Func<IServiceProvider,Object,Object>, ServiceLifetime) |
Создает экземпляр ServiceDescriptor с указанным |
| DescribeKeyed(Type, Object, Type, ServiceLifetime) |
Создает экземпляр ServiceDescriptor с указанным |
| Equals(Object) |
Определяет, равен ли указанный объект текущему объекту. (Унаследовано от Object) |
| GetHashCode() |
Служит хэш-функцией по умолчанию. (Унаследовано от Object) |
| GetType() |
Возвращает Type текущего экземпляра. (Унаследовано от Object) |
| KeyedScoped(Type, Object, Func<IServiceProvider,Object,Object>) |
Создает экземпляр ServiceDescriptor с указанным |
| KeyedScoped(Type, Object, Type) |
Создает экземпляр ServiceDescriptor с указанным |
| KeyedScoped<TService,TImplementation>(Object, Func<IServiceProvider,Object,TImplementation>) |
Создает экземпляр ServiceDescriptor с указанным |
| KeyedScoped<TService,TImplementation>(Object) |
Создает экземпляр ServiceDescriptor с указанным |
| KeyedScoped<TService>(Object, Func<IServiceProvider,Object,TService>) |
Создает экземпляр ServiceDescriptor с указанным |
| KeyedSingleton(Type, Object, Func<IServiceProvider,Object,Object>) |
Создает экземпляр ServiceDescriptor с указанным |
| KeyedSingleton(Type, Object, Object) |
Создает экземпляр ServiceDescriptor с указанным |
| KeyedSingleton(Type, Object, Type) |
Создает экземпляр ServiceDescriptor с указанным |
| KeyedSingleton<TService,TImplementation>(Object, Func<IServiceProvider,Object,TImplementation>) |
Создает экземпляр ServiceDescriptor с указанным |
| KeyedSingleton<TService,TImplementation>(Object) |
Создает экземпляр ServiceDescriptor с указанным |
| KeyedSingleton<TService>(Object, Func<IServiceProvider,Object,TService>) |
Создает экземпляр ServiceDescriptor с указанным |
| KeyedSingleton<TService>(Object, TService) |
Создает экземпляр ServiceDescriptor с указанным |
| KeyedTransient(Type, Object, Func<IServiceProvider,Object,Object>) |
Создает экземпляр ServiceDescriptor с указанным |
| KeyedTransient(Type, Object, Type) |
Создает экземпляр ServiceDescriptor с указанным |
| KeyedTransient<TService,TImplementation>(Object, Func<IServiceProvider,Object,TImplementation>) |
Создает экземпляр ServiceDescriptor с указанным |
| KeyedTransient<TService,TImplementation>(Object) |
Создает экземпляр ServiceDescriptor с указанным |
| KeyedTransient<TService>(Object, Func<IServiceProvider,Object,TService>) |
Создает экземпляр ServiceDescriptor с указанным |
| MemberwiseClone() |
Создает неглубокую копию текущей Object. (Унаследовано от Object) |
| Scoped(Type, Func<IServiceProvider,Object>) |
Создает экземпляр ServiceDescriptor с указанным |
| Scoped(Type, Type) |
Создает экземпляр ServiceDescriptor с указанным |
| Scoped<TService,TImplementation>() |
Создает экземпляр ServiceDescriptor с указанным |
| Scoped<TService,TImplementation>(Func<IServiceProvider,TImplementation>) |
Создает экземпляр ServiceDescriptor с указанным |
| Scoped<TService>(Func<IServiceProvider,TService>) |
Создает экземпляр ServiceDescriptor с указанным |
| Singleton(Type, Func<IServiceProvider,Object>) |
Создает экземпляр ServiceDescriptor с указанным |
| Singleton(Type, Object) |
Создает экземпляр ServiceDescriptor с указанным |
| Singleton(Type, Type) |
Создает экземпляр ServiceDescriptor с указанным |
| Singleton<TService,TImplementation>() |
Создает экземпляр ServiceDescriptor с указанным |
| Singleton<TService,TImplementation>(Func<IServiceProvider,TImplementation>) |
Создает экземпляр ServiceDescriptor с указанным |
| Singleton<TService>(Func<IServiceProvider,TService>) |
Создает экземпляр ServiceDescriptor с указанным |
| Singleton<TService>(TService) |
Создает экземпляр ServiceDescriptor с указанным |
| ToString() |
Возвращает строку, представляющую текущий объект. |
| Transient(Type, Func<IServiceProvider,Object>) |
Создает экземпляр ServiceDescriptor с указанным |
| Transient(Type, Type) |
Создает экземпляр ServiceDescriptor с указанным |
| Transient<TService,TImplementation>() |
Создает экземпляр ServiceDescriptor с указанным |
| Transient<TService,TImplementation>(Func<IServiceProvider,TImplementation>) |
Создает экземпляр ServiceDescriptor с указанным |
| Transient<TService>(Func<IServiceProvider,TService>) |
Создает экземпляр ServiceDescriptor с указанным |