Class Translations
java.lang.Object
net.minheur.potoflux.translations.Translations
the class that handle translations
-
Constructor Summary
Constructors -
Method Summary
-
Constructor Details
-
Translations
public Translations()
-
-
Method Details
-
registerTranslations
Adds a translation registry toallTranslations- Parameters:
registry- the reg to add translations from
-
load
Allow to changeloadedLang- Parameters:
lang- the lang you want to load- Returns:
- if the loaded lang has changed
-
load
Allow to changeloadedLang, by a lang code (String)- Parameters:
langCode- the code of the lang you want to load- Returns:
- if the loaded lang has changed
-
get
Get a translation in theloadedLangfrom its key- Parameters:
key- the key of the translation to get- Returns:
- the translation of the key in the
loadedLang
-