RequestLocalizationOptionsExtensions.AddInitialRequestCultureProvider 方法

定义

public:
[System::Runtime::CompilerServices::Extension]
 static Microsoft::AspNetCore::Builder::RequestLocalizationOptions ^ AddInitialRequestCultureProvider(Microsoft::AspNetCore::Builder::RequestLocalizationOptions ^ requestLocalizationOptions, Microsoft::AspNetCore::Localization::RequestCultureProvider ^ requestCultureProvider);
public static Microsoft.AspNetCore.Builder.RequestLocalizationOptions AddInitialRequestCultureProvider (this Microsoft.AspNetCore.Builder.RequestLocalizationOptions requestLocalizationOptions, Microsoft.AspNetCore.Localization.RequestCultureProvider requestCultureProvider);
static member AddInitialRequestCultureProvider : Microsoft.AspNetCore.Builder.RequestLocalizationOptions * Microsoft.AspNetCore.Localization.RequestCultureProvider -> Microsoft.AspNetCore.Builder.RequestLocalizationOptions
<Extension()>
Public Function AddInitialRequestCultureProvider (requestLocalizationOptions As RequestLocalizationOptions, requestCultureProvider As RequestCultureProvider) As RequestLocalizationOptions

参数

requestLocalizationOptions
RequestLocalizationOptions

要添加的区域性。

requestCultureProvider
RequestCultureProvider

要添加的区域性。

返回

RequestLocalizationOptions

注解

此方法确保 requestCultureProvider 优先于 RequestCultureProvider 中的其他 RequestCultureProviders实例。

适用于