interface OptionsServiceCollectionExtensions
cangjie
public interface OptionsServiceCollectionExtensions1
功能:定义选项服务注册与配置扩展接口。
扩展到
成员概览
func addOptions()
cangjie
func addOptions<TOptions>(): OptionsBuilder<TOptions> where TOptions <: Object1
功能:为指定选项类型注册默认名称的选项服务。
返回值:
- OptionsBuilder<TOptions> - 返回指定选项类型的构建器。
func addOptions(String)
cangjie
func addOptions<TOptions>(name: String): OptionsBuilder<TOptions> where TOptions <: Object1
功能:为指定名称的选项类型注册选项服务。
参数:
- name:
String- 选项名称。
返回值:
- OptionsBuilder<TOptions> - 返回指定选项类型的构建器。
func configure((TOptions) -> Unit)
cangjie
func configure<TOptions>(configureOptions: (TOptions) -> Unit): ServiceCollection where TOptions <: Object1
功能:为默认名称的选项注册配置委托。
参数:
- configureOptions:
(TOptions) -> Unit- 配置选项实例的委托。
返回值:
- ServiceCollection - 返回当前服务集合。
func configure(String, (TOptions) -> Unit)
cangjie
func configure<TOptions>(name: String, configureOptions: (TOptions) -> Unit): ServiceCollection where TOptions <: Object1
功能:为指定名称的选项注册配置委托。
参数:
- name:
String- 选项名称。 - configureOptions:
(TOptions) -> Unit- 配置选项实例的委托。
返回值:
- ServiceCollection - 返回当前服务集合。
func configureAfter((TOptions) -> Unit)
cangjie
func configureAfter<TOptions>(configureOptions: (TOptions) -> Unit): ServiceCollection where TOptions <: Object1
功能:为默认名称的选项注册后置配置委托。
参数:
- configureOptions:
(TOptions) -> Unit- 后置配置选项实例的委托。
返回值:
- ServiceCollection - 返回当前服务集合。
func configureAfter(String, (TOptions) -> Unit)
cangjie
func configureAfter<TOptions>(name: String, configureOptions: (TOptions) -> Unit): ServiceCollection where TOptions <: Object1
功能:为指定名称的选项注册后置配置委托。
参数:
- name:
String- 选项名称。 - configureOptions:
(TOptions) -> Unit- 后置配置选项实例的委托。
返回值:
- ServiceCollection - 返回当前服务集合。
func configure((TOptions, IServiceProvider) -> Unit)
cangjie
func configure<TOptions>(configureOptions: (TOptions, IServiceProvider) -> Unit): ServiceCollection where TOptions <: Object1
功能:为默认名称的选项注册可访问服务提供程序的配置委托。
参数:
- configureOptions: (TOptions, IServiceProvider) -> Unit - 配置选项实例的委托。
返回值:
- ServiceCollection - 返回当前服务集合。
func configure(String, (TOptions, IServiceProvider) -> Unit)
cangjie
func configure<TOptions>(name: String, configureOptions: (TOptions, IServiceProvider) -> Unit): ServiceCollection where TOptions <: Object1
功能:为指定名称的选项注册可访问服务提供程序的配置委托。
参数:
- name:
String- 选项名称。 - configureOptions: (TOptions, IServiceProvider) -> Unit - 配置选项实例的委托。
返回值:
- ServiceCollection - 返回当前服务集合。
func configureAfter((TOptions, IServiceProvider) -> Unit)
cangjie
func configureAfter<TOptions>(configureOptions: (TOptions, IServiceProvider) -> Unit): ServiceCollection where TOptions <: Object1
功能:为默认名称的选项注册可访问服务提供程序的后置配置委托。
参数:
- configureOptions: (TOptions, IServiceProvider) -> Unit - 后置配置选项实例的委托。
返回值:
- ServiceCollection - 返回当前服务集合。
func configureAfter(String, (TOptions, IServiceProvider) -> Unit)
cangjie
func configureAfter<TOptions>(name: String, configureOptions: (TOptions, IServiceProvider) -> Unit): ServiceCollection where TOptions <: Object1
功能:为指定名称的选项注册可访问服务提供程序的后置配置委托。
参数:
- name:
String- 选项名称。 - configureOptions: (TOptions, IServiceProvider) -> Unit - 后置配置选项实例的委托。
返回值:
- ServiceCollection - 返回当前服务集合。
func configureAll((TOptions) -> Unit)
cangjie
func configureAll<TOptions>(configureOptions: (TOptions) -> Unit): ServiceCollection where TOptions <: Object1
功能:为所有名称的选项注册统一配置委托。
参数:
- configureOptions:
(TOptions) -> Unit- 配置选项实例的委托。
返回值:
- ServiceCollection - 返回当前服务集合。
func configureAll((TOptions, IServiceProvider) -> Unit)
cangjie
func configureAll<TOptions>(configureOptions: (TOptions, IServiceProvider) -> Unit): ServiceCollection where TOptions <: Object1
功能:为所有名称的选项注册可访问服务提供程序的统一配置委托。
参数:
- configureOptions: (TOptions, IServiceProvider) -> Unit - 配置选项实例的委托。
返回值:
- ServiceCollection - 返回当前服务集合。
func configureAfterAll((TOptions) -> Unit)
cangjie
func configureAfterAll<TOptions>(configureOptions: (TOptions) -> Unit): ServiceCollection where TOptions <: Object1
功能:为所有名称的选项注册统一后置配置委托。
参数:
- configureOptions:
(TOptions) -> Unit- 后置配置选项实例的委托。
返回值:
- ServiceCollection - 返回当前服务集合。
func configureAfterAll((TOptions, IServiceProvider) -> Unit)
cangjie
func configureAfterAll<TOptions>(configureOptions: (TOptions, IServiceProvider) -> Unit): ServiceCollection where TOptions <: Object1
功能:为所有名称的选项注册可访问服务提供程序的统一后置配置委托。
参数:
- configureOptions: (TOptions, IServiceProvider) -> Unit - 后置配置选项实例的委托。
返回值:
- ServiceCollection - 返回当前服务集合。
func addOptionsWithValidateOnStart()
cangjie
func addOptionsWithValidateOnStart<TOptions>(): OptionsBuilder<TOptions> where TOptions <: Object1
功能:为默认名称的选项注册服务并启用启动时验证。
返回值:
- OptionsBuilder<TOptions> - 返回指定选项类型的构建器。
func addOptionsWithValidateOnStart(String)
cangjie
func addOptionsWithValidateOnStart<TOptions>(name: String): OptionsBuilder<TOptions> where TOptions <: Object1
功能:为指定名称的选项注册服务并启用启动时验证。
参数:
- name:
String- 选项名称。
返回值:
- OptionsBuilder<TOptions> - 返回指定选项类型的构建器。