RequestLocalizationOptions Class
Definition
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
Specifies options for the RequestLocalizationMiddleware.
public ref class RequestLocalizationOptions
public class RequestLocalizationOptions
type RequestLocalizationOptions = class
Public Class RequestLocalizationOptions
- Inheritance
-
RequestLocalizationOptions
Constructors
RequestLocalizationOptions() |
Creates a new RequestLocalizationOptions with default values. |
Properties
ApplyCurrentCultureToResponseHeaders |
Gets or sets a value that determines if CurrentUICulture is applied to the response |
CultureInfoUseUserOverride |
Configures UseUserOverride. Defaults to |
DefaultRequestCulture |
Gets or sets the default culture to use for requests when a supported culture could not be determined by one of the configured IRequestCultureProviders. Defaults to CurrentCulture and CurrentUICulture. |
FallBackToParentCultures |
Gets or sets a value indicating whether to set a request culture to an parent culture in the case the
culture determined by the configured IRequestCultureProviders is not in the
SupportedCultures list but a parent culture is.
Defaults to |
FallBackToParentUICultures |
Gets or sets a value indicating whether to set a request UI culture to a parent culture in the case the
UI culture determined by the configured IRequestCultureProviders is not in the
SupportedUICultures list but a parent culture is.
Defaults to |
RequestCultureProviders |
An ordered list of providers used to determine a request's culture information. The first provider that
returns a non- |
SupportedCultures |
The cultures supported by the application. The RequestLocalizationMiddleware will only set the current request culture to an entry in this list. Defaults to CurrentCulture. |
SupportedUICultures |
The UI cultures supported by the application. The RequestLocalizationMiddleware will only set the current request culture to an entry in this list. Defaults to CurrentUICulture. |
Methods
AddSupportedCultures(String[]) |
Adds the set of the supported cultures by the application. |
AddSupportedUICultures(String[]) |
Adds the set of the supported UI cultures by the application. |
SetDefaultCulture(String) |
Set the default culture which is used by the application when a supported culture could not be determined by one of the configured IRequestCultureProviders. |
Extension Methods
AddInitialRequestCultureProvider(RequestLocalizationOptions, RequestCultureProvider) |
Adds a new RequestCultureProvider to the RequestCultureProviders. |