Skip to main content

Documentation Index

Fetch the complete documentation index at: https://docs.kodeflowstudios.com/llms.txt

Use this file to discover all available pages before exploring further.

Static lookup and helpers for everything language-related. Declaration
public static class Localizer

Description

Central entry point for language metadata and runtime language state in Parley. Use it to resolve a LanguageID from an ISO code, look up a language’s English name and reading direction, or query the active language at runtime. All members are static.

Fields

FallbackLanguage

Default language used whenever a call doesn’t pass one explicitly. Declaration
public static LanguageID FallbackLanguage

FallbackTextDirection

Default text direction for the fallback language. Declaration
public static TextDirection FallbackTextDirection

Languages

The master registry that maps every to its ISO code, native spelling, and English name. Keep this in sync with the enum above, or lookups will throw at runtime. Declaration
public static readonly Dictionary<LanguageID, LanguageInfo> Languages

Methods

GetIDFromCode(string)

Finds a LanguageID by its lowercase ISO code (e.g. “en”). Declaration
public static LanguageID GetIDFromCode(string code)
Parameters
code
string
required
ISO 639-1 code (e.g. “en”). Case-insensitive. Must match an entry in Languages.
Returns
result
LanguageID
The LanguageID registered for the given code.

GetIDFromEnglishName(string)

Finds a LanguageID by its English name (e.g. “English”, “Arabic”). Case-insensitive. Declaration
public static LanguageID GetIDFromEnglishName(string name)
Parameters
name
string
required
English name for the language. Case-insensitive. Must match an entry in Languages.
Returns
result
LanguageID
The LanguageID registered for the given name.

GetInfoFromID(LanguageID)

Returns the full LanguageInfo for a given LanguageID. Declaration
public static LanguageInfo GetInfoFromID(LanguageID language)
Parameters
language
LanguageID
required
LanguageID for the language. Must match an entry in Languages and its correspondant in LanguageID.
Returns
result
LanguageInfo
The LanguageInfo registered for the given LanguageID.

GetInfoFromCode(string)

Returns the full for a given ISO 639-1 code (e.g. “en”). Case-insensitive. Declaration
public static LanguageInfo GetInfoFromCode(string code)
Parameters
code
string
required
ISO 639-1 code (e.g. “en”). Case-insensitive. Must match an entry in Languages.
Returns
result
LanguageInfo
The LanguageInfo registered for the given code.