共用方式為


OptionConfigureExtensionMethods.TryConfigureFormatterResolver<TOptions,TOptionFormatterResolver> 方法

定義

如果未設定任何名稱選項,請為具名選項 TOptions 設定選項格式器解析程式

public static Microsoft.Extensions.DependencyInjection.IServiceCollection TryConfigureFormatterResolver<TOptions,TOptionFormatterResolver> (this Microsoft.Extensions.DependencyInjection.IServiceCollection services) where TOptions : class where TOptionFormatterResolver : class, Orleans.IOptionFormatterResolver<TOptions>;
static member TryConfigureFormatterResolver : Microsoft.Extensions.DependencyInjection.IServiceCollection -> Microsoft.Extensions.DependencyInjection.IServiceCollection (requires 'Options : null and 'OptionFormatterResolver : null and 'OptionFormatterResolver :> Orleans.IOptionFormatterResolver<'Options>)
<Extension()>
Public Function TryConfigureFormatterResolver(Of TOptions As Class, TOptionFormatterResolver As Class) (services As IServiceCollection) As IServiceCollection

類型參數

TOptions
TOptionFormatterResolver

參數

傳回

適用於