Skip to main content
Version: 15.x (API 15) [Legacy]

Class ClientLanguageExtensions

Extension methods for the Dalamud.Common.ClientLanguage class.

Assembly: Dalamud.dll​
Declaration
public static class ClientLanguageExtensions

Methods​

ToLumina(ClientLanguage)​

Converts a Dalamud ClientLanguage to the corresponding Lumina variant.

Declaration
public static Language ToLumina(this ClientLanguage language)
Returns​

Lumina.Data.Language: Converted language.

Parameters​
TypeNameDescription
Dalamud.Common.ClientLanguagelanguageLanguage to convert.

ToCode(ClientLanguage)​

Gets the language code from a ClientLanguage.

Declaration
public static string ToCode(this ClientLanguage value)
Returns​

System.String: The language code (ja, en, de, fr).

Parameters​
TypeNameDescription
Dalamud.Common.ClientLanguagevalueThe ClientLanguage to convert.
Exceptions​

System.ArgumentOutOfRangeException
An exception that is thrown when no valid ClientLanguage was given.

ToClientLanguage(string)​

Gets the ClientLanguage from a language code.

Declaration
public static ClientLanguage ToClientLanguage(this string value)
Returns​

Dalamud.Common.ClientLanguage: The ClientLanguage.

Parameters​
TypeNameDescription
System.StringvalueThe language code to convert (ja, en, de, fr).
Exceptions​

System.ArgumentOutOfRangeException
An exception that is thrown when no valid language code was given.