Class I18NTool

    • Constructor Detail

      • I18NTool

        public I18NTool()
      • I18NTool

        public I18NTool​(Map<? extends String,​? extends String> m)
    • Method Detail

      • format

        public String format​(String key,
                             String value)
        Prints a formatted string
        Parameters:
        key - key of the string in the localization bundle
        value - is replaced into the {0} place holder
        Returns:
        the formatted string
      • format

        public String format​(String key,
                             String value1,
                             String value2)
        Prints a formatted string
        Parameters:
        key - key of the string in the localization bundle
        value1 - is replaced into the {0} place holder
        value2 - is replaced into the {1} place holder
        Returns:
        the formatted string
      • format

        public String format​(String key,
                             String value1,
                             String value2,
                             String value3)
        Prints a formatted string
        Parameters:
        key - key of the string in the localization bundle
        value1 - is replaced into the {0} place holder
        value2 - is replaced into the {1} place holder
        value3 - is replaced into the {2} place holder
        Returns:
        the formatted string
      • format

        public String format​(String key,
                             String value1,
                             String value2,
                             String value3,
                             String value4)
        Prints a formatted string
        Parameters:
        key - key of the string in the localization bundle
        value1 - is replaced into the {0} place holder
        value2 - is replaced into the {1} place holder
        value3 - is replaced into the {2} place holder
        value4 - is replaced into the {3} place holder
        Returns:
        the formatted string
      • format

        public String format​(String key,
                             String value1,
                             String value2,
                             String value3,
                             String value4,
                             String value5)
        Prints a formatted string
        Parameters:
        key - key of the string in the localization bundle
        value1 - is replaced into the {0} place holder
        value2 - is replaced into the {1} place holder
        value3 - is replaced into the {2} place holder
        value4 - is replaced into the {3} place holder
        value5 - is replaced into the {4} place holder
        Returns:
        the formatted string
      • format

        public String format​(String key,
                             String[] values)
        Prints a formatted string
        Parameters:
        key - key of the string in the localization bundle
        values - used to fill the place holders {X} will be replaced with values[X-1]
        Returns:
        the formatted string