Class Locale
A Locale represents a language. It supports regional variations and can be configured with an optional fallback locale.
Inheritance
System.Object
Locale
Syntax
public class Locale : ScriptableObject
Properties
FallbackLocale
An optional fallback locale can be configured to link Locales that may serve as good alternatives when no localization
data is available for the current locale.
Declaration
public Locale FallbackLocale { get; set; }
Property Value
Identifier
The identifier contains the identifying information such as the id and culture Code for this Locale.
Declaration
public LocaleIdentifier Identifier { get; set; }
Property Value
Methods
CreateLocale(CultureInfo)
Declaration
public static Locale CreateLocale(CultureInfo cultureInfo)
Parameters
Type |
Name |
Description |
System.Globalization.CultureInfo |
cultureInfo |
|
Returns
CreateLocale(String)
Declaration
public static Locale CreateLocale(string code)
Parameters
Type |
Name |
Description |
System.String |
code |
|
Returns
CreateLocale(SystemLanguage)
Declaration
public static Locale CreateLocale(SystemLanguage language)
Parameters
Type |
Name |
Description |
SystemLanguage |
language |
|
Returns
CreateLocale(LocaleIdentifier)
Declaration
public static Locale CreateLocale(LocaleIdentifier identifier)
Parameters
Returns
OnEnable()
Declaration
protected virtual void OnEnable()
ToString()
Declaration
public override string ToString()
Returns
Type |
Description |
System.String |
|