Table of Contents

Class ClientLocale

Namespace
RDCore.SDK.Server
Assembly
RDCore.SDK.dll

The language of the user interface a client says it shows (LSP 3.17 InitializeParams.locale), as the language a server speaks in: its diagnostics, its refusals, the titles of its actions, its hovers.

public static class ClientLocale
Inheritance
ClientLocale
Inherited Members

Remarks

Only the language of the user interface is the client's (CurrentUICulture). How numbers and dates are written and read is not: the semantics of the language do not depend on the culture of whoever reads them.

The language is the process's default as well as the current one, so that work the server begins later, on other threads - a child process it starts and initializes, which it tells the same locale - speaks it too.

Methods

Apply(string?)

Makes the language a client says it shows the language of the user interface.

public static CultureInfo? Apply(string? locale)

Parameters

locale string

The client's locale: a language tag such as fr-CA, en or de-ch.

Returns

CultureInfo

The culture now in use; null when the client says none, or one the platform does not know, which leaves the one in use.