Interface DeeplModule

All Superinterfaces:
ModuleSimple

public interface DeeplModule extends ModuleSimple
Translates messages through DeepL.
  • Method Details

    • config

      Description copied from interface: ModuleSimple
      The config section this module reads its settings from.
      Specified by:
      config in interface ModuleSimple
      Returns:
      the settings
    • permission

      Description copied from interface: ModuleSimple
      The permission that gates this module.
      Specified by:
      permission in interface ModuleSimple
      Returns:
      the permission
    • translate

      String translate(FPlayer sender, String source, String target, String text)
      Translates text through DeepL.
      Parameters:
      sender - who asked
      source - the language to translate from, or an empty string to detect it
      target - the language to translate into
      text - the text
      Returns:
      the translation, or the original text on failure