Class ResBundleUtils


  • public class ResBundleUtils
    extends Object
    This is a utility class providing methods to obtain localized messages for the delegation service.
    • Field Detail

      • bundle

        public static ResourceBundle bundle
        Resource bundle to be used to get messages from, using the default locale, specified in AMConfig.properties or OS locale if AMConfig.properties does not have locale defined
    • Constructor Detail

      • ResBundleUtils

        public ResBundleUtils()
    • Method Detail

      • getString

        public static String getString​(String key)
        gets localized string for the default locale specified in AMConfig.properties or if null based on the default OS locale.
        Parameters:
        key - to localized string
        Returns:
        localized string or key if localized string is missing
      • getString

        public static String getString​(String key,
                                       Object[] params)
        gets localized formatted string
        Parameters:
        key - to localized string
        params - parameters to be applied to the message
        Returns:
        localized string or key if localized string is missing, uses locale as set in AMConfig.properties or default OS locale.