java.lang.Object
i2p.susi.dns.Messages

public class Messagesextends Object
Translate strings for this package.
  • Field Details

  • Constructor Details

    • Messages

      public Messages()
      Create a new Messages instance.
  • Method Details

    • _t

      public String _t(String key)
      Translate a string.
      Parameters:
      key - the message key
      Returns:
      the translated string
    • _t

      public String _t(String key, Object o)
      Translate a string with one parameter.
      Parameters:
      key - the message key
      o - the value substituted into the translated message
      Returns:
      the translated string
    • getString

      public static String getString(String s)
      Translate a string (static).
      Parameters:
      s - the message key
      Returns:
      the translated string
    • getString

      public static String getString(String s, Object o)
      Translate a string with one parameter (static).
      Parameters:
      s - the message key
      o - the value substituted into the translated message
      Returns:
      the translated string
    • getString

      public static String getString(String s, Object o, Object o2)
      Translate a string with two parameters (static).
      Parameters:
      s - the message key
      o - the first parameter
      o2 - the second parameter
      Returns:
      the translated string
    • getString

      public static String getString(int n, String s, String p)
      Translate a string with plural form (ngettext).
      Parameters:
      n - the count that selects the singular or the plural form
      s - the singular form
      p - the plural form
      Returns:
      the translated string