Interface IContainerRegistrationRule
Правила регистрации компонента.
Namespace:InfinniPlatform.IoC
Assembly:InfinniPlatform.Core.Abstractions.dll
Syntax
public interface IContainerRegistrationRule
Methods
| Improve this Doc View SourceAs(Type[])
Определяет сервис, который предоставляет компонент.
Declaration
IContainerRegistrationRule As(params Type[] serviceTypes)
Parameters
Type | Name | Description |
---|---|---|
Type[] | serviceTypes | Типы сервисов. |
Returns
Type | Description |
---|---|
IContainerRegistrationRule |
As<TService>()
Определяет сервис, который предоставляет компонент.
Declaration
IContainerRegistrationRule As<TService>()
Returns
Type | Description |
---|---|
IContainerRegistrationRule |
Type Parameters
Name | Description |
---|---|
TService | Тип сервиса. |
AsImplementedInterfaces()
Определяет, что сервисами являются все интерфейсы, реализованные компонентом.
Declaration
IContainerRegistrationRule AsImplementedInterfaces()
Returns
Type | Description |
---|---|
IContainerRegistrationRule |
AsSelf()
Определяет, что сервисом является сам компонент.
Declaration
IContainerRegistrationRule AsSelf()
Returns
Type | Description |
---|---|
IContainerRegistrationRule |
ExternallyOwned()
Определяет, что зависимость никогда не освобождается контейнером.
Declaration
IContainerRegistrationRule ExternallyOwned()
Returns
Type | Description |
---|---|
IContainerRegistrationRule |
InstancePerDependency()
Определяет, что зависимость должна создаваться при каждом получении.
Declaration
IContainerRegistrationRule InstancePerDependency()
Returns
Type | Description |
---|---|
IContainerRegistrationRule |
InstancePerLifetimeScope()
Определяет, что зависимость должна создаваться на время выполнения запроса.
Declaration
IContainerRegistrationRule InstancePerLifetimeScope()
Returns
Type | Description |
---|---|
IContainerRegistrationRule |
SingleInstance()
Определяет, что зависимость создается один раз и навсегда.
Declaration
IContainerRegistrationRule SingleInstance()
Returns
Type | Description |
---|---|
IContainerRegistrationRule |