Package net.realdarkstudios.commons.util
Class Localization
java.lang.Object
net.realdarkstudios.commons.util.Localization
-
Method Summary
Modifier and TypeMethodDescriptionGets theRDSLogHelperinstance for this localizationorg.bukkit.plugin.PluginGets the prefix for this localizationgetTranslation(String key) Gets the translation of the given path.getTranslation(String key, Object... substitutions) Gets the translation of the given path with format argumentsbooleanhasTranslation(String key) Checks if a given translation exists
-
Method Details
-
getPlugin
public org.bukkit.plugin.Plugin getPlugin() -
getPrefix
Gets the prefix for this localization- Returns:
- The prefix
-
getLogHelper
Gets theRDSLogHelperinstance for this localization- Returns:
- The
RDSLogHelper
-
getTranslation
Gets the translation of the given path. No format arguments.- Parameters:
key- The path of the translation- Returns:
- The translated message
-
getTranslation
Gets the translation of the given path with format arguments- Parameters:
key- The path of the translationsubstitutions- The format argument substitutions- Returns:
- The translated message
-
hasTranslation
Checks if a given translation exists- Parameters:
key- The path of the translation- Returns:
trueif an entry exists,falseif not
-
getTranslations
-