C# Class Spring.Globalization.Resolvers.RequestCultureResolver

Culture resolver that uses request headers to determine culture. If no languages are specified in the request headers, it returns default culture specifed, and if no default culture was specifed it returns current culture for the executing server thread.
Note: This culture resolver cannot be used to change the culture because request headers cannot be modified. In order to change the culture when using this culture resolver user has to change language settings in the web browser.
Inheritance: Spring.Globalization.Resolvers.DefaultWebCultureResolver
显示文件 Open project: spring-projects/spring-net

Public Methods

Method Description
ResolveCulture ( ) : CultureInfo

Tries to determine culture from the request headers. If no languages are specified in the request headers, it returns default culture specifed, and if no default culture was specifed it returns current culture for the executing server thread.

SetCulture ( CultureInfo culture ) : void

Not supported for this resolver implementation

Method Details

ResolveCulture() public method

Tries to determine culture from the request headers. If no languages are specified in the request headers, it returns default culture specifed, and if no default culture was specifed it returns current culture for the executing server thread.
public ResolveCulture ( ) : CultureInfo
return System.Globalization.CultureInfo

SetCulture() public method

Not supported for this resolver implementation
public SetCulture ( CultureInfo culture ) : void
culture System.Globalization.CultureInfo The new culture or null to clear the culture.
return void