Class Localization

java.lang.Object
net.realdarkstudios.commons.util.Localization

public class Localization extends Object
  • Method Details

    • getPlugin

      public org.bukkit.plugin.Plugin getPlugin()
    • getPrefix

      public String getPrefix()
      Gets the prefix for this localization
      Returns:
      The prefix
    • getLogHelper

      public RDSLogHelper getLogHelper()
      Gets the RDSLogHelper instance for this localization
      Returns:
      The RDSLogHelper
    • getTranslation

      public String getTranslation(String key)
      Gets the translation of the given path. No format arguments.
      Parameters:
      key - The path of the translation
      Returns:
      The translated message
    • getTranslation

      public String getTranslation(String key, Object... substitutions)
      Gets the translation of the given path with format arguments
      Parameters:
      key - The path of the translation
      substitutions - The format argument substitutions
      Returns:
      The translated message
    • hasTranslation

      public boolean hasTranslation(String key)
      Checks if a given translation exists
      Parameters:
      key - The path of the translation
      Returns:
      true if an entry exists, false if not
    • getTranslations

      public HashMap<String,String> getTranslations()