Class TranslationRepository

java.lang.Object
me.lucko.luckperms.common.locale.TranslationRepository

public class TranslationRepository extends Object
  • Constructor Details

    • TranslationRepository

      public TranslationRepository(LuckPermsPlugin plugin)
  • Method Details

    • getAvailableLanguages

      Gets a list of available languages.
      Returns:
      a list of languages
      Throws:
      IOException - if an i/o error occurs
      UnsuccessfulRequestException - if the http request fails
    • scheduleRefresh

      public void scheduleRefresh()
      Schedules a refresh of the current translations if necessary.
    • downloadAndInstallTranslations

      public void downloadAndInstallTranslations(List<TranslationRepository.LanguageInfo> languages, @Nullable Sender sender, boolean updateStatus)
      Downloads and installs translations for the given languages.
      Parameters:
      languages - the languages to install translations for
      sender - the sender to report progress to
      updateStatus - if the status file should be updated