getLocalizedName

fun getLocalizedName(localizedString: String, languageCode: String): String

Parses the given localized string and returns the text corresponding to the specified language. If the entry in the requested language does not exist, the method attempts to localize the string in English. If that fails too, the whole raw string is returned. An example of a valid localized string is "|en:hello|fi:terve|".

Parameters

localizedString

The input string, which may be localized or not.

languageCode

The requested language code, e.g. "fi" or "en".